projects
/
lttng-ci.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ansible: Add play to run produce known_hosts file using ssh-keyscan
[lttng-ci.git]
/
automation
/
ansible
/
playbooks
/
dist-upgrade.yml
diff --git
a/automation/ansible/playbooks/dist-upgrade.yml
b/automation/ansible/playbooks/dist-upgrade.yml
index 13cce7373ec2262cabffaabdd6791b00d7da4f41..57d011da6942571aeaddf00591096829b3fa341e 100644
(file)
--- a/
automation/ansible/playbooks/dist-upgrade.yml
+++ b/
automation/ansible/playbooks/dist-upgrade.yml
@@
-1,5
+1,5
@@
---
---
-- name: Dist upgrade and option
n
al reboot
+- name: Dist upgrade and optional reboot
hosts: all
vars:
restart: 'no'
hosts: all
vars:
restart: 'no'
@@
-18,8
+18,10
@@
- name: apt-get dist-upgrade
apt: upgrade=dist
- 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"
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
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
- 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
timeout=300
state=started
when: last_result.changed
-
sudo
: false
+
become
: false
This page took
0.022794 seconds
and
4
git commands to generate.