Add windows updates playbook
This commit is contained in:
15
windows/windows_update.yml
Normal file
15
windows/windows_update.yml
Normal file
@@ -0,0 +1,15 @@
|
||||
---
|
||||
- name: Windows Updates
|
||||
hosts: windows
|
||||
tasks:
|
||||
- name: Check for available updates
|
||||
win_updates:
|
||||
state: searched
|
||||
|
||||
- name: Download updates
|
||||
win_updates:
|
||||
state: installed
|
||||
|
||||
- name: Reboot if required
|
||||
win_reboot:
|
||||
when: ansible_reboot_pending | bool
|
||||
Reference in New Issue
Block a user