From 77bebb1a087447c09eea428178ea3d27adfc054d Mon Sep 17 00:00:00 2001 From: Pavlos Daoglou Date: Sun, 13 Dec 2020 13:54:31 +0200 Subject: [PATCH] updates syntax and deprecated include statements --- ansible/playbooks/init-rocky-install-kvm-hosts.yml | 13 ++++++------- ansible/playbooks/init-rocky-ipa-team.yml | 6 +++--- ansible/playbooks/init-rocky-system-config.yml | 10 +++++----- ansible/playbooks/role-rocky-ipa-replica.yml | 2 +- ansible/playbooks/role-rocky-ipa.yml | 2 +- ansible/playbooks/role-rocky-ipsilon.yml | 2 +- 6 files changed, 17 insertions(+), 18 deletions(-) diff --git a/ansible/playbooks/init-rocky-install-kvm-hosts.yml b/ansible/playbooks/init-rocky-install-kvm-hosts.yml index 1d737c6..c20b1de 100644 --- a/ansible/playbooks/init-rocky-install-kvm-hosts.yml +++ b/ansible/playbooks/init-rocky-install-kvm-hosts.yml @@ -28,14 +28,13 @@ # Install KVM packages - name: Installing KVM Packages package: - name: "{{ item }}" + name: + - qemu-kvm + - libvirt + - libvirt-python + - libguestfs-tools + - virt-install state: present - with_items: - - qemu-kvm - - libvirt - - libvirt-python - - libguestfs-tools - - virt-install - name: Enable and Start libvirtd systemd: diff --git a/ansible/playbooks/init-rocky-ipa-team.yml b/ansible/playbooks/init-rocky-ipa-team.yml index 3d8af84..edf2b1c 100644 --- a/ansible/playbooks/init-rocky-ipa-team.yml +++ b/ansible/playbooks/init-rocky-ipa-team.yml @@ -19,10 +19,10 @@ fail_msg: "We are missing users or ipa admin password" - name: "Start users" - include: import-rockyusers.yml + import_playbook: import-rockyusers.yml - name: "Start groups" - include: import-rockygroups.yml + import_playbook: import-rockygroups.yml - name: "Start sudo for admins" - include: import-rockysudo.yml + import_playbook: import-rockysudo.yml diff --git a/ansible/playbooks/init-rocky-system-config.yml b/ansible/playbooks/init-rocky-system-config.yml index 2bc6d12..a929c44 100644 --- a/ansible/playbooks/init-rocky-system-config.yml +++ b/ansible/playbooks/init-rocky-system-config.yml @@ -6,7 +6,7 @@ # This is to try to avoid the handler issue in pre/post tasks handlers: - - include: handlers/main.yml + - import_tasks: handlers/main.yml pre_tasks: - name: Check if ansible cannot be run here @@ -22,16 +22,16 @@ tasks: - name: Loading Variables from OS Common - include: tasks/variable_loader_common.yml + import_tasks: tasks/variable_loader_common.yml - name: Configure SSH - include: tasks/ssh_config.yml + import_tasks: tasks/ssh_config.yml - name: Configure harden settings - include: tasks/harden.yml + import_tasks: tasks/harden.yml - name: Configure PAM - include: tasks/authentication.yml + import_tasks: tasks/authentication.yml post_tasks: - name: Touching run file that ansible has ran here diff --git a/ansible/playbooks/role-rocky-ipa-replica.yml b/ansible/playbooks/role-rocky-ipa-replica.yml index aa9511a..4226d7e 100644 --- a/ansible/playbooks/role-rocky-ipa-replica.yml +++ b/ansible/playbooks/role-rocky-ipa-replica.yml @@ -9,7 +9,7 @@ # This is to try to avoid the handler issue in pre/post tasks handlers: - - include: handlers/main.yml + - import_tasks: handlers/main.yml pre_tasks: - name: Check if ansible cannot be run here diff --git a/ansible/playbooks/role-rocky-ipa.yml b/ansible/playbooks/role-rocky-ipa.yml index d219c17..ceef2dd 100644 --- a/ansible/playbooks/role-rocky-ipa.yml +++ b/ansible/playbooks/role-rocky-ipa.yml @@ -13,7 +13,7 @@ # This is to try to avoid the handler issue in pre/post tasks handlers: - - include: handlers/main.yml + - import_tasks: handlers/main.yml pre_tasks: - name: Check if ansible cannot be run here diff --git a/ansible/playbooks/role-rocky-ipsilon.yml b/ansible/playbooks/role-rocky-ipsilon.yml index 4e84dba..4cfb353 100644 --- a/ansible/playbooks/role-rocky-ipsilon.yml +++ b/ansible/playbooks/role-rocky-ipsilon.yml @@ -8,7 +8,7 @@ # This is to try to avoid the handler issue in pre/post tasks handlers: - - include: handlers/main.yml + - import_tasks: handlers/main.yml pre_tasks: - name: Check if ansible cannot be run here