From 3d8b111a82663d32bc4270ba91bf4f71325ba287 Mon Sep 17 00:00:00 2001 From: jaydee Date: Fri, 16 Dec 2022 22:09:02 +0100 Subject: [PATCH] dayoff --- hosts.yml | 1 + playbooks/70_install_k3s.yml | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/hosts.yml b/hosts.yml index ea8d64d..79b0be3 100644 --- a/hosts.yml +++ b/hosts.yml @@ -17,6 +17,7 @@ datacenter: ansible_ssh_pass: lacijaydee ansible_become_password: lacijaydee ssh_args: "-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no" + ansible_ssh_common_args: "-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no" nas: diff --git a/playbooks/70_install_k3s.yml b/playbooks/70_install_k3s.yml index d120a8a..78bac2b 100644 --- a/playbooks/70_install_k3s.yml +++ b/playbooks/70_install_k3s.yml @@ -69,3 +69,9 @@ # ansible.builtin.shell: curl --insecure -sfL https://192.168.77.106:8543/v3/import/f5679ncdtx68489nqj2rntk8bwv6lcsq4j5qdtnxswkbfbtttn5s5q_c-lq4j4.yaml |sed 's/rancher-agent:v2.6.7/rancher-agent:v2.6.7-linux-arm64/g'| sed 's%beta.kubernetes.io/os%kubernetes.io/os%g'| kubectl apply -f - # changed_when: false # ignore_errors: true + - name: wait for pods to come up + shell: kubectl get pods -o json -n cattle-system + register: kubectl_get_pods + until: kubectl_get_pods.stdout|from_json|json_query('items[*].status.phase')|unique == ["Running"] + retries: 20 + delay: 30 \ No newline at end of file