From b757e21b2a559870957d76878143c8c2d2908958 Mon Sep 17 00:00:00 2001 From: Wong Hoi Sing Edison Date: Thu, 6 May 2021 15:01:12 +0800 Subject: [PATCH] https://github.com/ansible-community/ansible-lint/pull/1540 --- playbooks/cleanup.yml | 10 +++++----- playbooks/converge.yml | 4 ++-- playbooks/prepare.yml | 26 +++++++++++++------------- playbooks/tasks/redhat.yml | 2 +- playbooks/tasks/suse.yml | 2 +- roles/catatonit | 2 +- roles/gosu | 2 +- roles/locales | 2 +- roles/python | 2 +- roles/sshd | 2 +- roles/timezone | 2 +- 11 files changed, 28 insertions(+), 28 deletions(-) diff --git a/playbooks/cleanup.yml b/playbooks/cleanup.yml index 0146d08..821f6f9 100644 --- a/playbooks/cleanup.yml +++ b/playbooks/cleanup.yml @@ -26,7 +26,7 @@ rm -rf /root/.cache/* rm -rf /tmp/* changed_when: false - ignore_errors: true + failed_when: false - name: debian | apt-get -y clean raw: | @@ -36,7 +36,7 @@ apt-get -y clean rm -rf /var/lib/apt/lists/* changed_when: false - ignore_errors: true + failed_when: false - name: redhat | yum clean all raw: | @@ -44,7 +44,7 @@ yum clean all rm -rf /var/cache/yum/* changed_when: false - ignore_errors: true + failed_when: false - name: suse | zypper clean --all raw: | @@ -52,7 +52,7 @@ zypper clean --all rm -rf /var/cache/zypper/* changed_when: false - ignore_errors: true + failed_when: false - name: redhat | subscription-manager unregister raw: | @@ -61,4 +61,4 @@ subscription-manager unregister subscription-manager clean changed_when: false - ignore_errors: true + failed_when: false diff --git a/playbooks/converge.yml b/playbooks/converge.yml index 5427d56..dafccd2 100644 --- a/playbooks/converge.yml +++ b/playbooks/converge.yml @@ -33,7 +33,7 @@ - "{{ ansible_os_family | lower }}.yml" paths: - "./vars" - ignore_errors: true + failed_when: false - name: include release specific tasks include_tasks: "{{ lookup('first_found', _params) }}" @@ -47,7 +47,7 @@ - "{{ ansible_os_family | lower }}.yml" paths: - "./tasks" - ignore_errors: true + failed_when: false - name: include default tasks include_tasks: "./tasks/main.yml" diff --git a/playbooks/prepare.yml b/playbooks/prepare.yml index a700fce..48eacf6 100644 --- a/playbooks/prepare.yml +++ b/playbooks/prepare.yml @@ -27,7 +27,7 @@ --password={{ lookup('env', 'REDHAT_PASSWORD') }} \ --auto-attach changed_when: false - ignore_errors: true + failed_when: false - name: debian | apt-get install python3 python3-dev raw: | @@ -36,7 +36,7 @@ DEBIAN_FRONTEND=noninteractive apt-get dist-upgrade -y DEBIAN_FRONTEND=noninteractive apt-get install -y python3 python3-dev changed_when: false - ignore_errors: true + failed_when: false - name: redhat | yum install python3 python3-devel raw: | @@ -45,7 +45,7 @@ yum update -y yum install -y python3 python3-devel changed_when: false - ignore_errors: true + failed_when: false - name: suse | zypper install python3 python3-devel raw: | @@ -54,7 +54,7 @@ zypper -n update -y zypper -n install -y python3 python3-devel changed_when: false - ignore_errors: true + failed_when: false - hosts: all remote_user: root @@ -65,7 +65,7 @@ set -eu cp -rfT /etc/skel /root changed_when: false - ignore_errors: true + failed_when: false - name: setenforce 0 raw: | @@ -73,7 +73,7 @@ setenforce 0 sed -i 's/^SELINUX=.*$/SELINUX=permissive/g' /etc/selinux/config changed_when: false - ignore_errors: true + failed_when: false - name: systemctl stop firewalld.service raw: | @@ -81,7 +81,7 @@ systemctl stop firewalld.service systemctl disable firewalld.service changed_when: false - ignore_errors: true + failed_when: false - name: systemctl stop ufw.service raw: | @@ -89,7 +89,7 @@ systemctl stop ufw.service systemctl disable ufw.service changed_when: false - ignore_errors: true + failed_when: false - name: debian | apt-get install *.deb raw: | @@ -97,7 +97,7 @@ DEBIAN_FRONTEND=noninteractive apt-get install -y bzip2 ca-certificates curl gcc gnupg gzip iproute2 procps python3 python3-apt python3-cryptography python3-dev python3-jmespath python3-lxml python3-netaddr python3-pip python3-setuptools python3-venv python3-virtualenv python3-wheel sudo tar unzip xz-utils zip when: ansible_os_family | lower == "debian" changed_when: false - ignore_errors: true + failed_when: false - name: fedora | yum install *.rpm raw: | @@ -105,7 +105,7 @@ yum install -y bzip2 ca-certificates curl gcc gnupg2 gzip iproute procps-ng python3 python3-cryptography python3-devel python3-jmespath python3-libselinux python3-lxml python3-netaddr python3-pip python3-setuptools python3-virtualenv python3-wheel sudo tar unzip xz yum-utils zip when: ansible_distribution | lower == "fedora" changed_when: false - ignore_errors: true + failed_when: false - name: redhat-8 | yum install *.rpm raw: | @@ -114,7 +114,7 @@ yum install -y bzip2 ca-certificates curl gcc gnupg2 gzip iproute procps-ng python3 python3-cryptography python3-devel python3-jmespath python3-libselinux python3-lxml python3-netaddr python3-pip python3-setuptools python3-virtualenv python3-wheel sudo tar unzip xz yum-utils zip when: ansible_os_family | lower == "redhat" and ansible_distribution_major_version | lower == "8" changed_when: false - ignore_errors: true + failed_when: false - name: redhat-7 | yum install *.rpm raw: | @@ -124,7 +124,7 @@ yum install -y bzip2 ca-certificates curl gcc gnupg2 gzip iproute procps-ng python3 python36-cryptography python3-devel python3-jmespath python3-libselinux python36-netaddr python3-lxml python3-pip python3-setuptools python3-virtualenv python3-wheel sudo tar unzip xz yum-utils zip when: ansible_os_family | lower == "redhat" and ansible_distribution_major_version | lower == "7" changed_when: false - ignore_errors: true + failed_when: false - name: suse | zypper -n install *.rpm raw: | @@ -132,4 +132,4 @@ zypper -n install -y bzip2 ca-certificates curl gcc gpg2 gzip iproute2 procps python3 python3-cryptography python3-devel python3-jmespath python3-lxml python3-netaddr python3-pip python3-setuptools python3-virtualenv python3-wheel sudo tar unzip xz zip when: ansible_os_family | lower == "suse" changed_when: false - ignore_errors: true + failed_when: false diff --git a/playbooks/tasks/redhat.yml b/playbooks/tasks/redhat.yml index 0f48cc0..cf162f4 100644 --- a/playbooks/tasks/redhat.yml +++ b/playbooks/tasks/redhat.yml @@ -18,7 +18,7 @@ command: yum-config-manager --{{ item.state }} {{ item.name }} loop: "{{ _yum_config_manager }}" changed_when: false - ignore_errors: true + failed_when: false - name: yum install yum: diff --git a/playbooks/tasks/suse.yml b/playbooks/tasks/suse.yml index b6d90bc..dc52643 100644 --- a/playbooks/tasks/suse.yml +++ b/playbooks/tasks/suse.yml @@ -19,7 +19,7 @@ set -eu rm -rf /etc/zypp/repos.d/* changed_when: false - ignore_errors: true + failed_when: false - name: zypper addrepo vars: diff --git a/roles/catatonit b/roles/catatonit index d4f10b7..b053d0e 160000 --- a/roles/catatonit +++ b/roles/catatonit @@ -1 +1 @@ -Subproject commit d4f10b770fa3c96149a3ab994aeb2a9b937b96e7 +Subproject commit b053d0ed610c55e09933e6bc5f61718228a4c0c1 diff --git a/roles/gosu b/roles/gosu index 030e338..5109230 160000 --- a/roles/gosu +++ b/roles/gosu @@ -1 +1 @@ -Subproject commit 030e338a6d31851b1ad5823b7157c76c79f1f92f +Subproject commit 5109230748ad0dc4ab8f51710ceddd3cc2ed8d48 diff --git a/roles/locales b/roles/locales index d294c53..bd32283 160000 --- a/roles/locales +++ b/roles/locales @@ -1 +1 @@ -Subproject commit d294c53a98d6f9c3bf1af7d65eb010b0729ada17 +Subproject commit bd3228315e0c3aa925eb664b3683a5594676aad5 diff --git a/roles/python b/roles/python index fc2714d..bc834d8 160000 --- a/roles/python +++ b/roles/python @@ -1 +1 @@ -Subproject commit fc2714df4f217910d751aa38c9c4114779eedcc1 +Subproject commit bc834d89dfa5b509b0df87d667ceab0a1d770f87 diff --git a/roles/sshd b/roles/sshd index 3653b61..5cd74e0 160000 --- a/roles/sshd +++ b/roles/sshd @@ -1 +1 @@ -Subproject commit 3653b6141694223aa51df5b87b847789b864e306 +Subproject commit 5cd74e091f24ca874b8b155311f74d3b1a3b5e6c diff --git a/roles/timezone b/roles/timezone index ecda258..3e144c1 160000 --- a/roles/timezone +++ b/roles/timezone @@ -1 +1 @@ -Subproject commit ecda258ec1add41afaf01496b7a407a724bc2311 +Subproject commit 3e144c1f82080197e27bc0eaa628d490a3d7edab