Refactor playbook_microk8s.yml and ansible-apply.yaml

Simplify playbook_microk8s.yml by removing duplicate lines and whitespace changes.
Update ansible-apply.yaml to include a scheduled job for Terraform Apply.
This commit is contained in:
2024-09-28 21:27:24 +02:00
parent bad1668115
commit 1f060541c3
12 changed files with 136 additions and 233 deletions
+3 -3
View File
@@ -124,7 +124,7 @@
- k8s::iac
- name: Get new config SHA1
set_fact:
ansible.builtin.set_fact:
patched_kubeconfig_sha1: "{{ patched_kubeconfig_yaml | to_nice_yaml | sha1 }}"
tags:
- k8s::iac
@@ -136,6 +136,6 @@
dest: "{{ k8s_kubeconfig }}"
owner: "{{ k8s_iac_user }}"
mode: "0600"
when: kubeconfig_exists.stat.exists == false or patched_kubeconfig_sha1 != kubeconfig_exists.stat.checksum
when: not kubeconfig_exists.stat.exists or patched_kubeconfig_sha1 != kubeconfig_exists.stat.checksum
tags:
- k8s::iac
- k8s::iac