1313
1414- [ Description] ( #description )
1515- [ Setup] ( #setup )
16- - [ Setup Requirements] ( #setup-requirements )
17- - [ Getting started ] ( #getting-started )
16+ - [ Setup Requirements] ( #setup-requirements )
17+ - [ Quick Start ] ( #quick-start )
1818- [ Architecture] ( #architecture )
1919- [ Design] ( #design )
2020- [ Patching Workflow] ( #patching-workflow )
2121- [ Usage] ( #usage )
22- - [ Check for available updates] ( #check-for-available-updates )
23- - [ Create snapshots] ( #create-snapshots )
24- - [ Perform pre-patching checks and actions] ( #perform-pre-patching-checks-and-actions )
25- - [ Run a the full patching workflow end-to-end] ( #run-a-the-full-patching-workflow-end-to-end )
22+ - [ Check for available updates] ( #check-for-available-updates )
23+ - [ Disable monitoring] ( #disable-monitoring )
24+ - [ Create snapshots] ( #create-snapshots )
25+ - [ Perform pre-patching checks and actions] ( #perform-pre-patching-checks-and-actions )
26+ - [ Deploying pre/post patching scripts] ( #deploying-prepost-patching-scripts )
27+ - [ Run a the full patching workflow end-to-end] ( #run-a-the-full-patching-workflow-end-to-end )
28+ - [ Patching with Puppet Enterprise (PE)] ( #patching-with-puppet-enterprise-pe )
2629- [ Configuration Options] ( #configuration-options )
2730- [ Reference] ( #reference )
2831- [ Limitations] ( #limitations )
2932- [ Development] ( #development )
3033- [ Contributors] ( #contributors )
3134
35+
3236## Description
3337
3438A framework for building patching workflows. This module is designed to be used as building
3539blocks for complex patching environments of Windows and Linux (RHEL, Ubuntu) systems.
3640
37- No Puppet agent is required on the end nodes . The node executing the patching will need to
41+ No Puppet agent is required on the end targets . The node executing the patching will need to
3842have ` bolt ` installed.
3943
4044## Setup
@@ -62,7 +66,7 @@ mod 'encore/patching'
6266EOF
6367
6468bolt puppetfile install
65- bolt plan run patching::available_updates --nodes group_a
69+ bolt plan run patching::available_updates --targets group_a
6670
6771# install rbvmomi for VMware snapshot support
6872/opt/puppetlabs/bolt/bin/gem install --user-install rbvmomi
@@ -73,9 +77,9 @@ bolt plan run patching::available_updates --nodes group_a
7377This module is designed to work in enterprise patching environments.
7478
7579Assumptions:
76- * RHEL nodes are registered to Satellite / Foreman or the internet
77- * Ubuntu nodes are registered to Landscape or the internet
78- * Windows nodes are registered to WSUS and Chocolatey (optional)
80+ * RHEL targets are registered to Satellite / Foreman or the internet
81+ * Ubuntu targets are registered to Landscape or the internet
82+ * Windows targets are registered to WSUS and Chocolatey (optional)
7983
8084Registration to a central patching server is preferred for speed of software downloads
8185and control of phased patching promotions.
@@ -90,7 +94,7 @@ these central patching server tools.
9094` patching ` is designed around ` bolt ` tasks and plans.
9195
9296Individual tasks have been written to accomplish targeted steps in the patching process.
93- Examples: ` patching::available_updates ` is used to check for available updates on target nodes .
97+ Examples: ` patching::available_updates ` is used to check for available updates on targets .
9498
9599Plans are then used to pretty up output and tie tasks together.
96100
@@ -125,14 +129,14 @@ This workflow consists of the following phases:
125129
126130### Check for available updates
127131
128- This will reach out to all nodes in ` group_a ` in your inventory and check for any available
132+ This will reach out to all targets in ` group_a ` in your inventory and check for any available
129133updates through the system's package manager:
130134* RHEL = yum
131135* Ubuntu = apt
132136* Windows = Windows Update + Chocolatey (if installed)
133137
134138``` shell
135- bolt plan run patching::available_updates --nodes group_a
139+ bolt plan run patching::available_updates --targets group_a
136140```
137141
138142### Disable monitoring
@@ -144,7 +148,7 @@ This plan/task utilizes the `remote` transport []
144148
145149
146150``` shell
147- bolt plan run patching::monitoring_solarwinds --nodes group_a action=disable' monitoring_target=solarwinds
151+ bolt plan run patching::monitoring_solarwinds --targets group_a action=disable' monitoring_target=solarwinds
148152```
149153
150154### Create snapshots
@@ -155,7 +159,7 @@ be the `uri` of the node the inventory file.
155159``` shell
156160/opt/puppetlabs/bolt/bin/gem install rbvmomi
157161
158- bolt plan run patching::snapshot_vmware --nodes group_a action=' create' vsphere_host=' vsphere.domain.tld' vsphere_username=' xyz' vsphere_password=' abc123' vsphere_datacenter=' dctr1'
162+ bolt plan run patching::snapshot_vmware --targets group_a action=' create' vsphere_host=' vsphere.domain.tld' vsphere_username=' xyz' vsphere_password=' abc123' vsphere_datacenter=' dctr1'
159163```
160164
161165### Perform pre-patching checks and actions
@@ -168,10 +172,10 @@ Best practice is to define and distribute these scripts as part of your normal P
168172as part of othe role for that node.
169173
170174``` shell
171- bolt plan run patching::pre_update --nodes group_a
175+ bolt plan run patching::pre_update --targets group_a
172176```
173177
174- By default this executes the following scripts (nodes where the script doesn' t exist are ignored):
178+ By default this executes the following scripts (targets where the script doesn' t exist are ignored):
175179* Linux = ` /opt/patching/bin/pre_update.sh`
176180* Windows = ` C:\P rogramData\p atching\p re_update.ps1`
177181
@@ -232,17 +236,46 @@ Then, for each group:
232236* ` patching::snapshot_vmware action=' delete' `
233237
234238` ` ` shell
235- bolt plan run patching --nodes group_a
239+ bolt plan run patching --targets group_a
240+ ` ` `
241+
242+ # ## Patching with Puppet Enterprise (PE)
243+
244+ When executing patching with Puppet Enterprise Bolt will use the ` pcp` transport.
245+ This transport has a default timeout of ` 1000` seconds. Windows patching is MUCH
246+ slower than this and the timeouts will need to be increased.
247+
248+ If you do not modify this default timeout, you may experience the following error
249+ in the ` patching::update` task or any other long running task:
250+
251+ ` ` ` yaml
252+ Starting: task patching::update on windowshost.company.com
253+ Finished: task patching::update with 1 failure in 1044.63 sec
254+ The following hosts failed during update:
255+ [{" target" :" windowshost.company.com" ," action" :" task" ," object" :" patching::update" ," status" :" failure" ," result" :{" _output" :" null" ," _error" :{" kind" :" puppetlabs.tasks/task-error" ," issue_code" :" TASK_ERROR" ," msg" :" The task failed with exit code unknown" ," details" :{" exit_code" :" unknown" }}}," node" :" windowshost.company.com" }]
256+ ` ` `
257+
258+ Below is an example ` bolt.yaml` with the settings modified:
259+
260+ ` ` ` yaml
261+ ---
262+ pcp:
263+ # 2 hours = 120 minutes = 7,200 seconds
264+ job-poll-timeout: 7200
236265` ` `
237266
267+ For a complete reference of the available settings for the ` pcp` transport see
268+ [bolt configuration reference](https://puppet.com/docs/bolt/latest/bolt_configuration_reference.html)
269+ documentation.
270+
238271# # Configuration Options
239272
240273This module allows many aspects of its runtime to be customized using configuration options
241274in the inventory file.
242275
243276For details on all of the available configuration options, see [REFERENCE_CONFIGURATION.md](REFERENCE_CONFIGURATION.md)
244277
245- Example: Let' s say we want to prevent some nodes from rebooting during patching.
278+ Example: Let' s say we want to prevent some targets from rebooting during patching.
246279This can be customized with the `patching_reboot_strategy` variable in inventory:
247280
248281``` yaml
0 commit comments