From 7cc36eb2c7142d1b4ebf9f2d4867dcda96aea851 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcel=20K=C3=B6rtgen?= Date: Wed, 27 Mar 2024 18:25:33 +0100 Subject: [PATCH] fix: replace include deprecations, #13 --- roles/kvm/tasks/main.yml | 12 ++++++------ roles/lxd/tasks/main.yml | 12 ++++++------ roles/packer/tasks/main.yml | 2 +- roles/podman/tasks/main.yml | 10 +++++----- roles/virtualbox/tasks/main.yml | 14 +++++++------- roles/vmtools/tasks/main.yml | 6 +++--- roles/vmvagrant/tasks/main.yml | 14 +++++++------- roles/vmware/tasks/main.yml | 16 ++++++++-------- 8 files changed, 43 insertions(+), 43 deletions(-) diff --git a/roles/kvm/tasks/main.yml b/roles/kvm/tasks/main.yml index dec3c48..6637c87 100644 --- a/roles/kvm/tasks/main.yml +++ b/roles/kvm/tasks/main.yml @@ -1,19 +1,19 @@ --- # tasks file for kvm -- include: install_CentOS.yml +- include_tasks: install_CentOS.yml when: ansible_facts['distribution'] == "CentOS" and ansible_facts['distribution_version']|int <= 7 -- include: install_RedHat.yml +- include_tasks: install_RedHat.yml when: ansible_facts['distribution'] == "RedHat" and ansible_facts['distribution_version']|int <= 8 -- include: install_Fedora.yml +- include_tasks: install_Fedora.yml when: ansible_facts['distribution'] == "Fedora" and ansible_facts['distribution_version']|int == 30 -- include: install_Ubuntu.yml +- include_tasks: install_Ubuntu.yml when: ansible_facts['distribution'] == "Ubuntu" and ansible_facts['distribution_version'] >= "18.04" -- include: install_Debian.yml +- include_tasks: install_Debian.yml when: ansible_facts['distribution'] == "Debian" and ansible_facts['distribution_version']|int >= 10 -- include: configure.yml +- include_tasks: configure.yml diff --git a/roles/lxd/tasks/main.yml b/roles/lxd/tasks/main.yml index 0a89f3e..290dfa5 100644 --- a/roles/lxd/tasks/main.yml +++ b/roles/lxd/tasks/main.yml @@ -1,20 +1,20 @@ --- # tasks file for lxd -- include: install_CentOS.yml +- include_tasks: install_CentOS.yml when: ansible_facts['distribution'] == "CentOS" and ansible_facts['distribution_version']|int <= 7 -- include: install_Fedora.yml +- include_tasks: install_Fedora.yml when: ansible_facts['distribution'] == "Fedora" and ansible_facts['distribution_version']|int == 30 -- include: install_Ubuntu.yml +- include_tasks: install_Ubuntu.yml when: ansible_facts['distribution'] == "Ubuntu" and ansible_facts['distribution_version'] == "18.04" -- include: install_Debian.yml +- include_tasks: install_Debian.yml when: ansible_facts['distribution'] == "Debian" and ansible_facts['distribution_version']|int >= 10 -- include: snap.yml +- include_tasks: snap.yml when: ansible_facts['distribution'] != 'RedHat' -- include: configure.yml +- include_tasks: configure.yml when: ansible_facts['distribution'] != 'RedHat' diff --git a/roles/packer/tasks/main.yml b/roles/packer/tasks/main.yml index 3aa4e54..d13fd14 100644 --- a/roles/packer/tasks/main.yml +++ b/roles/packer/tasks/main.yml @@ -1,7 +1,7 @@ --- # tasks file for packer ## OS Specific first -- include: install_Debian.yml +- include_tasks: install_Debian.yml when: ansible_facts['os_family'] == "Debian" ## General OSes diff --git a/roles/podman/tasks/main.yml b/roles/podman/tasks/main.yml index 53694ad..ddff9f8 100644 --- a/roles/podman/tasks/main.yml +++ b/roles/podman/tasks/main.yml @@ -1,16 +1,16 @@ --- # tasks file for podman -- include: install_CentOS.yml +- include_tasks: install_CentOS.yml when: ansible_facts['distribution'] == "CentOS" and ansible_facts['distribution_version']|int <= 8 -- include: install_RedHat.yml +- include_tasks: install_RedHat.yml when: ansible_facts['distribution'] == "RedHat" and ansible_facts['distribution_version']|int <= 8 -- include: install_Fedora.yml +- include_tasks: install_Fedora.yml when: ansible_facts['distribution'] == "Fedora" and ansible_facts['distribution_version']|int == 30 -- include: install_Ubuntu.yml +- include_tasks: install_Ubuntu.yml when: ansible_facts['distribution'] == "Ubuntu" and ansible_facts['distribution_version'] == "18.04" -- include: configure.yml +- include_tasks: configure.yml diff --git a/roles/virtualbox/tasks/main.yml b/roles/virtualbox/tasks/main.yml index adcb3d2..f0c0c3e 100644 --- a/roles/virtualbox/tasks/main.yml +++ b/roles/virtualbox/tasks/main.yml @@ -1,27 +1,27 @@ --- # tasks file for virtualbox -- name: 'CentOS' +- name: "CentOS" include_tasks: install_CentOS.yml when: ansible_facts['distribution'] == "CentOS" and ansible_facts['distribution_version']|int <= 7 -- name: 'Debian' +- name: "Debian" include_tasks: install_Debian.yml when: ansible_facts['distribution'] == "Debian" and ansible_facts['distribution_version']|int >= 10 -- name: 'Fedora' +- name: "Fedora" include_tasks: install_Fedora.yml when: ansible_facts['distribution'] == "Fedora" and ansible_facts['distribution_version']|int == 30 -- name: 'RedHat' +- name: "RedHat" include_tasks: install_RedHat.yml when: ansible_facts['distribution'] == "RedHat" and ansible_facts['distribution_version']|int <= 8 -- name: 'Ubuntu' +- name: "Ubuntu" include_tasks: install_Ubuntu.yml when: ansible_facts['distribution'] == "Ubuntu" and ansible_facts['distribution_version'] >= "18.04" -- include: configure.yml +- include_tasks: configure.yml -- include: extensions.yml +- include_tasks: extensions.yml when: install_extpacks diff --git a/roles/vmtools/tasks/main.yml b/roles/vmtools/tasks/main.yml index 80c13ed..0df327a 100644 --- a/roles/vmtools/tasks/main.yml +++ b/roles/vmtools/tasks/main.yml @@ -17,13 +17,13 @@ - ansible_virtualization_role == "guest" # VirtualBox -- include: VirtualBox.yml +- include_tasks: VirtualBox.yml when: ansible_virtualization_type == "virtualbox" # VMware -- include: VMware.yml +- include_tasks: VMware.yml when: ansible_virtualization_type == "vmware" # KVM -- include: KVM.yml +- include_tasks: KVM.yml when: ansible_virtualization_type == "kvm" diff --git a/roles/vmvagrant/tasks/main.yml b/roles/vmvagrant/tasks/main.yml index 037dd69..c61e4c6 100644 --- a/roles/vmvagrant/tasks/main.yml +++ b/roles/vmvagrant/tasks/main.yml @@ -2,12 +2,12 @@ # tasks file for vmvagrant # Virtualization and vagrant setup -- include: disable-ipv6.yml # Disable IPv6 -- include: sudoers.yml # Setup sudoers file -- include: hosts.yml # Update /etc/hosts -- include: vagrant.yml # Create vagrant SSH key -- include: sshd.yml # Setup sshd -- include: network.yml # Network fixes +- include_tasks: disable-ipv6.yml # Disable IPv6 +- include_tasks: sudoers.yml # Setup sudoers file +- include_tasks: hosts.yml # Update /etc/hosts +- include_tasks: vagrant.yml # Create vagrant SSH key +- include_tasks: sshd.yml # Setup sshd +- include_tasks: network.yml # Network fixes # Cleanup -- include: cleanup.yml # Cleanup +- include_tasks: cleanup.yml # Cleanup diff --git a/roles/vmware/tasks/main.yml b/roles/vmware/tasks/main.yml index c2f6f2f..58bf974 100644 --- a/roles/vmware/tasks/main.yml +++ b/roles/vmware/tasks/main.yml @@ -1,24 +1,24 @@ --- # tasks file for vmware -- include: install_CentOS.yml +- include_tasks: install_CentOS.yml when: ansible_facts['distribution'] == "CentOS" and ansible_facts['distribution_version']|int <= 7 -- include: install_RedHat.yml +- include_tasks: install_RedHat.yml when: ansible_facts['distribution'] == "RedHat" and ansible_facts['distribution_version']|int <= 8 -- include: install_Fedora.yml +- include_tasks: install_Fedora.yml when: ansible_facts['distribution'] == "Fedora" and ansible_facts['distribution_version']|int == 30 -- include: install_Ubuntu.yml +- include_tasks: install_Ubuntu.yml when: ansible_facts['distribution'] == "Ubuntu" and ansible_facts['distribution_version'] >= "18.04" -- include: install_Debian.yml +- include_tasks: install_Debian.yml when: ansible_facts['distribution'] == "Debian" and ansible_facts['distribution_version']|int >= 10 -- include: install_VMware.yml +- include_tasks: install_VMware.yml -- include: patch_Fedora.yml +- include_tasks: patch_Fedora.yml when: ansible_facts['distribution'] == "Fedora" and ansible_facts['distribution_major_version']|int == 30 -- include: configure.yml +- include_tasks: configure.yml