diff --git a/tasks/main.yml b/tasks/main.yml index 077dcae42593243d7ba447572d177b9be2b2d582..06afd7d31323fb357ae1b2b78559b4de4c9068d4 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -17,6 +17,10 @@ shell: kubectl delete ns/lab11 failed_when: false +- name: K8s + shell: /usr/local/bin/kubectl patch service prometheus -n prometheus --type='json' -p='[{"op": "replace", "path": "/metadata/labels/app", "value": "loki"}]' + failed_when: false + - name: Named lineinfile: dest: /etc/named.conf @@ -45,11 +49,6 @@ line: "myorigin = localhost" state: present -- name: NFS - file: - dest: /etc/exports - state: absent - - name: Filesystems ansible.posix.mount: path: /mnt/nfs @@ -84,3 +83,19 @@ with_items: - httpd - postfix + +- name: Exports + file: + path: '/etc/exports' + state: absent + +- name: Exports + file: + path: '/etc/exports' + state: touch + +- name: Exports + shell: exportfs -a + +- name: Unconditionally reboot the machine with all defaults + ansible.builtin.reboot: