homeserver/ansible: add playbook to spin up k8s cluster

- add new playbook to spin-up kubernetes cluster using k0sctl and
  k0sctl config file
This commit is contained in:
2025-06-28 13:37:19 +03:00
parent 6a9aefa02d
commit cba783b7ba
7 changed files with 213 additions and 2 deletions

View File

@ -1,4 +1,22 @@
apt_packages:
- curl
- vim
- htop
- htop
# Kubernetes k0sctl configuration vars
master1_ip: "192.168.1.151"
master1_hostname: "vm6"
master2_ip: "192.168.1.161"
master2_hostname: "vm8"
worker1_ip: "192.168.1.152"
worker1_hostname: "vm7"
worker2_ip: "192.168.1.162"
worker2_hostname: "vm9"
pod_CIDR: "10.244.0.0/16"
service_CIDR: "10.96.0.0/12"
metallb_ip_range: "192.168.1.201-192.168.1.220"
k0s_version: "v1.33.2+k0s.0"
metallb_version: "0.15.2"
traefik_version: "36.2.0"

View File

@ -17,7 +17,7 @@ vm_list:
ip: "192.168.1.152/24"
gateway: "192.168.1.1"
nameserver1: "192.168.1.145"
nameserver2: "8.8.8.8"
nameserver2: "1.1.1.1"
# cloud-init variables
node: "homeserver1"