Use port 1022 for all cluster nodes as SSH-port and fix some config-errors

I'm oversaw completely, that I have to change the SSH-port for all nodes
in the cluster otherwise I cannot provide a meaningful load-balancer for
the git-ssh port in it.

Additionally this allowed me to fix some config errors which I simply
oversaw.
This commit is contained in:
2025-09-22 03:43:37 +02:00
parent f1856f59aa
commit f19a1f61c9
8 changed files with 63 additions and 8 deletions

View File

@@ -1,6 +1,6 @@
all:
vars:
k8s_api_endpoint: "{{ hostvars[groups['server'][0]]['ansible_host'] | default(groups['server'][0]) }}"
api_endpoint: "{{ hostvars[groups['server'][0]]['ansible_host'] | default(groups['server'][0]) }}"
cert_manager_state: present
cert_manager_version: v1.18.2
letsencrypt_clusterissuers:
@@ -19,7 +19,7 @@ k3s_cluster:
agent:
vars:
ansible_ssh_common_args: -o StrictHostKeyChecking=accept-new -o ProxyCommand="ssh -p 1022 -W %h:%p -q root@{{ k8s_api_endpoint }}"
ansible_ssh_common_args: -o StrictHostKeyChecking=accept-new -o ProxyCommand="ssh -p {{ hostvars[groups['server'][0]]['ansible_port'] }} -W %h:%p -q root@{{ api_endpoint }}"
k3s_version: v1.31.6+k3s1
server: