diff --git a/main.yml b/main.yml index 513a2c3..9a79141 100644 --- a/main.yml +++ b/main.yml @@ -87,4 +87,4 @@ - name: Reboot system when: hypervisor != "libvirt" ansible.builtin.command: reboot - ignore_errors: true + failed_when: false diff --git a/roles/cleanup/tasks/main.yml b/roles/cleanup/tasks/main.yml index fbd7b9d..43e59af 100644 --- a/roles/cleanup/tasks/main.yml +++ b/roles/cleanup/tasks/main.yml @@ -20,7 +20,7 @@ - name: Remove CD-ROM from VM in vCenter when: hypervisor == "vmware" delegate_to: localhost - ignore_errors: true + failed_when: false community.vmware.vmware_guest: hostname: "{{ hypervisor_url }}" username: "{{ hypervisor_username }}" diff --git a/roles/configuration/tasks/main.yml b/roles/configuration/tasks/main.yml index e73a1a4..55f8d26 100644 --- a/roles/configuration/tasks/main.yml +++ b/roles/configuration/tasks/main.yml @@ -111,7 +111,7 @@ - name: Extra Configuration block: - name: Append lines to vimrc - ignore_errors: true + failed_when: false ansible.builtin.lineinfile: path: "{{ '/mnt/etc/vim/vimrc' if os | lower in ['debian11', 'debian12', 'ubuntu', 'ubuntu-lts'] else '/mnt/etc/vimrc' }}" line: "{{ item }}" diff --git a/roles/partitioning/tasks/main.yml b/roles/partitioning/tasks/main.yml index 80d0dc9..f38c0f3 100644 --- a/roles/partitioning/tasks/main.yml +++ b/roles/partitioning/tasks/main.yml @@ -2,7 +2,7 @@ - name: Partition install drive block: - name: Prepare partitions - ignore_errors: true + failed_when: false ansible.builtin.command: "{{ item.cmd }}" loop: - { cmd: umount -l /mnt }