gamethis.wsus_server
WSUS Server
This guide helps you install and set up the WSUS (Windows Server Update Services) for Windows Server 2016 and 2019.
Requirements
You just need the standard setup for Ansible to work on your system.
Role Variables
The following settings can be found in /defaults/main.yml
:
wsus_install_management_tools
: Decide if you want to install the WSUS Management Console. Default isyes
.wsus_content_folder
: Choose where WSUS will keep its downloaded updates. Default isC:\WSUS
.wsus_products_list
: List of products for which updates will be available. Default includesWindows Server 2016
andWindows Server 2019
.wsus_classifications_list
: List of update types to be enabled. Default includesCritical Updates
andSecurity Updates
.wsus_use_proxy
: Indicates if a proxy will be used for the WSUS server. Default isno
, but this only applies ifwsus_port
andwsus_proxy
are set.wsus_enable_default_approval_rule
: Turn the default approval rule on or off. Default istrue
.wsus_category_sync_timeout_minutes
: Sets how long to wait (in minutes) before a sync times out. Default is1000
.wsus_languages
: List of languages for updates. Default isen
(English).wsus_chocolatey_source
: Default location for community Chocolatey packages. Default ishttp://chocolatey.org/api/v2
.wsus_remove_default_website
: Decide if you want to remove the default IIS website. Default istrue
.wsus_install_report_viewer
: Decide if you want to install the report viewer. Default isTrue
.wsus_computer_target_group_list
: Groups to create on the WSUS server. Default groups areServers
andWorkStations
.wsus_targeting_mode
: How to set target groups, with options asServer
andClient
.wsus_sync_daily_time
:
This sets the time for automatic updates, withhour: 0 minute: 0
hour: 0
representing midnight.
More settings can be found in /vars/main.yml
:
wsus_script_folder
: Location for WSUS scripts. Default isC:\WSUS\Scripts\
.wsus_log_folder
: Location for WSUS logs. Default isC:\WSUS\Logs
.wsus_facts
: Indicates if WSUS facts should be collected.
Dependencies
There are no known dependencies.
Example Playbook
Here's a sample playbook using this role:
---
- hosts: all
vars:
ansible_user: 'administrator'
ansible_become_user: System
ansible_become_method: runas
ansible_shell_type: powershell
ansible_host_key_checking: False
ansible_ssh_common_args: '-C -o ControlMaster=auto -o ControlPersist=180s -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null'
wait_for_sync: True
roles:
- wsus
License
MIT License
Author Information
Created by @gamthis (Larry Lane)