Switching to ansible_connection to conditionally run tasks.

This commit is contained in:
Robert de Bock 2020-06-10 13:47:26 +02:00
parent f03b8c4cb1
commit ddbb9afe76

View file

@ -3,8 +3,7 @@
- name: update grub
command: "{{ grub_update_grub_command }}"
when:
- ansible_virtualization_type != "docker"
- ansible_virtualization_type != "container"
- ansible_connection != "docker"
notify:
- reboot