fix(k3s_server): use VIP address in kubeconfig instead of k3s_server_name

k3s_server_name resolves to k3s.seyshiro.de which has no DNS entry.
Use k3s_vip (192.168.20.2) so the kubeconfig always works.
This commit is contained in:
Tuan-Dat Tran
2026-04-27 21:41:55 +02:00
parent e8df950e87
commit b4e093c9b1

View File

@@ -46,7 +46,7 @@
- name: Add K3s cluster to kubeconfig
ansible.builtin.command: >
kubectl config set-cluster "{{ k3s_cluster_name }}"
--server="https://{{ k3s_server_name }}:6443"
--server="https://{{ k3s_vip }}:6443"
--certificate-authority=/tmp/k3s-ca.crt
--embed-certs=true
environment: