ansible: Add play to run produce known_hosts file using ssh-keyscan
[lttng-ci.git] / automation / ansible / playbooks / dist-upgrade.yml
index 13cce7373ec2262cabffaabdd6791b00d7da4f41..57d011da6942571aeaddf00591096829b3fa341e 100644 (file)
@@ -1,5 +1,5 @@
 ---
-- name: Dist upgrade and optionnal reboot
+- name: Dist upgrade and optional reboot
   hosts: all
   vars:
     restart: 'no'
    - name: apt-get dist-upgrade
      apt: upgrade=dist
 
-   - name: apt-get autoremove 
-     command: apt-get -y --purge autoremove
+   - name: apt-get autoremove
+     command:
+       cmd: apt-get -y --purge autoremove
+       warn: false
      register: autoremove_output
      changed_when: "'The following packages will be REMOVED' in autoremove_output.stdout"
 
@@ -30,7 +32,7 @@
      ignore_errors: true
      when: reboot == "yes"
      register: last_result
+
    - name: wait for the server to reboot
      local_action: wait_for host={{ inventory_hostname }}
                    port=22
@@ -38,4 +40,4 @@
                    timeout=300
                    state=started
      when: last_result.changed
-     sudo: false
+     become: false
This page took 0.042171 seconds and 4 git commands to generate.