vhost_update: add in some basic excludes handling

Signed-off-by: Kevin Fenzi <kevin@scrye.com>
This commit is contained in:
Kevin Fenzi 2019-04-10 21:18:52 +00:00
parent 0614cbd83b
commit 1ff28544c1

View file

@ -42,6 +42,7 @@
user: root
tasks:
- name: Apply updates
package:
state: latest
@ -49,6 +50,23 @@
update_cache: true
async: 7200
poll: 30
- debug:
msg:
- '!!!!!!!!!!!!!!!!!!! host {{ inventory_hostname }} has EXCLUDES OF {{ package_excludes }} !!!!!!!!!!!!!'
- '!!!!!!!!!!!!!!!!!!! DANGER DANGER DANGER ^ CHECK THAT EXCLUDES ARE STILL NEEDED ^ !!!!!!!!!!!!!!!!!!!!'
when: package_excludes is defined
changed_when: true
- name: Apply updates with excludes
package:
state: latest
name: "*"
update_cache: true
exclude: "{{ package_excludes }}"
async: 7200
poll: 30
when: package_excludes is defined
- name: run rkhunter if installed
hosts: "{{ target }}:myvms_new"