Commit 98249746 authored by Simon Cornet's avatar Simon Cornet
Browse files

feat: move tag logic to playbook file

parent 23c72d19
Loading
Loading
Loading
Loading
Loading
+13 −4
Original line number Diff line number Diff line
@@ -16,7 +16,16 @@
      changed_when: false
      failed_when: false

    # execute the role
    - name: "execute role: toolbox"
      ansible.builtin.include_role:
        name: "toolbox"
    # install updates
    - name: "install updates"
      tags:
        - "update"
        - "never"
      ansible.builtin.include_tasks: "tasks/update.yaml"
    
    # initiate reboot
    - name: "initiate reboot"
      tags:
        - "reboot"
        - "never"
      ansible.builtin.include_tasks: "tasks/reboot.yaml"

tasks/main.yaml

deleted100644 → 0
+0 −15
Original line number Diff line number Diff line
---

# install updates
- name: "install updates"
  tags:
    - "update"
    - "never"
  ansible.builtin.include_tasks: "update.yaml"

# initiate reboot
- name: "initiate reboot"
  tags:
    - "reboot"
    - "never"
  ansible.builtin.include_tasks: "reboot.yaml"
+0 −3
Original line number Diff line number Diff line
@@ -2,9 +2,6 @@

# reboot the system
- name: "reboot the system"
  tags:
    - "update"
    - "never"
  ansible.builtin.reboot:
    msg: "Reboot initiated by Ansible"
    reboot_timeout: 120
+0 −3
Original line number Diff line number Diff line
@@ -2,9 +2,6 @@

# install updates
- name: "install updates"
  tags:
    - "update"
    - "never"
  block:

    # install updates - alpine