Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/francoposa/learn-infra-ops
Learning infrastructure & operations. Ansible, Docker, Kubernetes, and Helm on Digital Ocean VMs.
https://github.com/francoposa/learn-infra-ops
ansible digitalocean docker helm k3s k8s kubernetes
Last synced: 3 months ago
JSON representation
Learning infrastructure & operations. Ansible, Docker, Kubernetes, and Helm on Digital Ocean VMs.
- Host: GitHub
- URL: https://github.com/francoposa/learn-infra-ops
- Owner: francoposa
- License: mit
- Created: 2020-06-16T15:01:20.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2024-07-09T21:48:28.000Z (7 months ago)
- Last Synced: 2024-07-10T02:13:37.060Z (7 months ago)
- Topics: ansible, digitalocean, docker, helm, k3s, k8s, kubernetes
- Language: Shell
- Homepage: https://francoposa.io/resources/infra-ops/
- Size: 9.23 MB
- Stars: 5
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# learn-infra-ops
## Development
#### Installing dev dependencies
```
% poetry install --no-root
```#### Linting the YAML files in this repo:
From the project root directory, yamllint uses the `.yamllint.yaml` file for configuration:
```
% yamllint .
```## Cloud Infrastructure
### Deploying K3s on a Digitalocean VM
From the root directory:
```shell
export DO_API_TOKEN=dop_v1_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx# Add the ssh key for the VM to the keychain
ssh-add ~/.ssh/id_ed25519_infra_ops # ssh key for the DO droplet# Create a new DigitalOcean VM
ansible-playbook ./infrastructure/ansible/inventory/mgmt/digitalocean-demo-create.yaml# Run a quick demo do verify ssh access
ansible-playbook -i ./infrastructure/ansible/inventory/sources/ ./infrastructure/ansible/inventory/mgmt/digitalocean-demo-shell-example.yaml# Install k3s on the single VM
ansible-playbook -i ./infrastructure/ansible/inventory/sources/digitalocean.yaml ./infrastructure/ansible/k3s/install.yaml# Copy the kubeconfig for the cluster to local; merge with existing kubeconfigs
ansible-playbook -i ./infrastructure/ansible/inventory/sources/ ./infrastructure/ansible/k3s/local-kube-config.yaml# verify connectivity to k3s cluster
kubectl cluster-info
kubectl get nodes
```