mirror of
https://pagure.io/fedora-infra/ansible.git
synced 2026-03-20 03:57:02 +08:00
firt cut of package-update playbook - needs testing
This commit is contained in:
22
playbooks/package-update.yml
Normal file
22
playbooks/package-update.yml
Normal file
@@ -0,0 +1,22 @@
|
||||
# requires --extra-vars="hostlist='host1 host2 group etc'"
|
||||
|
||||
- name: update all run rkhunter if installed
|
||||
hosts: $hostlist
|
||||
user: root
|
||||
|
||||
tasks:
|
||||
- name: yum update
|
||||
action: command yum -y update
|
||||
|
||||
- name: check for rkhunter
|
||||
action: command /usr/bin/test -f /usr/bin/rkhunter
|
||||
register: rkhunter
|
||||
|
||||
- name: run rkhunter --propupd
|
||||
action: command /usr/bin/rkhunter --propupd
|
||||
only_if: "'${rkhunter.rc}' == '0'"
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user