blob: 9e2b421b53b76c26b54f93240d5c088d23f23e93 [file] [log] [blame]
Bu Sun Kim65020912020-05-20 12:08:20 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
Bu Sun Kim673ec5c2020-11-16 11:05:03 -070075<h1><a href="osconfig_v1.html">OS Config API</a> . <a href="osconfig_v1.projects.html">projects</a> . <a href="osconfig_v1.projects.patchJobs.html">patchJobs</a></h1>
Bu Sun Kim65020912020-05-20 12:08:20 -070076<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="osconfig_v1.projects.patchJobs.instanceDetails.html">instanceDetails()</a></code>
79</p>
80<p class="firstline">Returns the instanceDetails Resource.</p>
81
82<p class="toc_element">
83 <code><a href="#cancel">cancel(name, body=None, x__xgafv=None)</a></code></p>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070084<p class="firstline">Cancel a patch job. The patch job must be active. Canceled patch jobs cannot be restarted.</p>
85<p class="toc_element">
86 <code><a href="#close">close()</a></code></p>
87<p class="firstline">Close httplib2 connections.</p>
Bu Sun Kim65020912020-05-20 12:08:20 -070088<p class="toc_element">
89 <code><a href="#execute">execute(parent, body=None, x__xgafv=None)</a></code></p>
90<p class="firstline">Patch VM instances by creating and running a patch job.</p>
91<p class="toc_element">
92 <code><a href="#get">get(name, x__xgafv=None)</a></code></p>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -070093<p class="firstline">Get the patch job. This can be used to track the progress of an ongoing patch job or review the details of completed jobs.</p>
Bu Sun Kim65020912020-05-20 12:08:20 -070094<p class="toc_element">
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -080095 <code><a href="#list">list(parent, filter=None, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
Bu Sun Kim65020912020-05-20 12:08:20 -070096<p class="firstline">Get a list of patch jobs.</p>
97<p class="toc_element">
98 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
99<p class="firstline">Retrieves the next page of results.</p>
100<h3>Method Details</h3>
101<div class="method">
102 <code class="details" id="cancel">cancel(name, body=None, x__xgafv=None)</code>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700103 <pre>Cancel a patch job. The patch job must be active. Canceled patch jobs cannot be restarted.
Bu Sun Kim65020912020-05-20 12:08:20 -0700104
105Args:
106 name: string, Required. Name of the patch in the form `projects/*/patchJobs/*` (required)
107 body: object, The request body.
108 The object takes the form of:
109
110{ # Message for canceling a patch job.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800111}
Bu Sun Kim65020912020-05-20 12:08:20 -0700112
113 x__xgafv: string, V1 error format.
114 Allowed values
115 1 - v1 error format
116 2 - v2 error format
117
118Returns:
119 An object of the form:
120
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700121 { # A high level representation of a patch job that is either in progress or has completed. Instance details are not included in the job. To paginate through instance details, use ListPatchJobInstanceDetails. For more information about patch jobs, see [Creating patch jobs](https://cloud.google.com/compute/docs/os-patch-management/create-patch-job).
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800122 &quot;createTime&quot;: &quot;A String&quot;, # Time this patch job was created.
123 &quot;description&quot;: &quot;A String&quot;, # Description of the patch job. Length of the description is limited to 1024 characters.
124 &quot;displayName&quot;: &quot;A String&quot;, # Display name for this patch job. This is not a unique identifier.
125 &quot;dryRun&quot;: True or False, # If this patch job is a dry run, the agent reports that it has finished without running any updates on the VM instance.
126 &quot;duration&quot;: &quot;A String&quot;, # Duration of the patch job. After the duration ends, the patch job times out.
127 &quot;errorMessage&quot;: &quot;A String&quot;, # If this patch job failed, this message provides information about the failure.
128 &quot;instanceDetailsSummary&quot;: { # A summary of the current patch state across all instances that this patch job affects. Contains counts of instances in different states. These states map to `InstancePatchState`. List patch job instance details to see the specific states of each instance. # Summary of instance details.
129 &quot;ackedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have acked and will start shortly.
130 &quot;applyingPatchesInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are applying patches.
131 &quot;downloadingPatchesInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are downloading patches.
132 &quot;failedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that failed.
133 &quot;inactiveInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are inactive.
134 &quot;noAgentDetectedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that do not appear to be running the agent. Check to ensure that the agent is installed, running, and able to communicate with the service.
135 &quot;notifiedInstanceCount&quot;: &quot;A String&quot;, # Number of instances notified about patch job.
136 &quot;pendingInstanceCount&quot;: &quot;A String&quot;, # Number of instances pending patch job.
137 &quot;postPatchStepInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are running the post-patch step.
138 &quot;prePatchStepInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are running the pre-patch step.
139 &quot;rebootingInstanceCount&quot;: &quot;A String&quot;, # Number of instances rebooting.
140 &quot;startedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have started.
141 &quot;succeededInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have completed successfully.
142 &quot;succeededRebootRequiredInstanceCount&quot;: &quot;A String&quot;, # Number of instances that require reboot.
143 &quot;timedOutInstanceCount&quot;: &quot;A String&quot;, # Number of instances that exceeded the time out while applying the patch.
144 },
145 &quot;instanceFilter&quot;: { # A filter to target VM instances for patching. The targeted VMs must meet all criteria specified. So if both labels and zones are specified, the patch job targets only VMs with those labels and in those zones. # Instances to patch.
146 &quot;all&quot;: True or False, # Target all VM instances in the project. If true, no other criteria is permitted.
147 &quot;groupLabels&quot;: [ # Targets VM instances matching ANY of these GroupLabels. This allows targeting of disparate groups of VM instances.
148 { # Targets a group of VM instances by using their [assigned labels](https://cloud.google.com/compute/docs/labeling-resources). Labels are key-value pairs. A `GroupLabel` is a combination of labels that is used to target VMs for a patch job. For example, a patch job can target VMs that have the following `GroupLabel`: `{&quot;env&quot;:&quot;test&quot;, &quot;app&quot;:&quot;web&quot;}`. This means that the patch job is applied to VMs that have both the labels `env=test` and `app=web`.
149 &quot;labels&quot;: { # Compute Engine instance labels that must be present for a VM instance to be targeted by this filter.
150 &quot;a_key&quot;: &quot;A String&quot;,
151 },
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800152 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800153 ],
154 &quot;instanceNamePrefixes&quot;: [ # Targets VMs whose name starts with one of these prefixes. Similar to labels, this is another way to group VMs when targeting configs, for example prefix=&quot;prod-&quot;.
155 &quot;A String&quot;,
156 ],
157 &quot;instances&quot;: [ # Targets any of the VM instances specified. Instances are specified by their URI in the form `zones/[ZONE]/instances/[INSTANCE_NAME]`, `projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`, or `https://www.googleapis.com/compute/v1/projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`
158 &quot;A String&quot;,
159 ],
160 &quot;zones&quot;: [ # Targets VM instances in ANY of these zones. Leave empty to target VM instances in any zone.
161 &quot;A String&quot;,
162 ],
163 },
164 &quot;name&quot;: &quot;A String&quot;, # Unique identifier for this patch job in the form `projects/*/patchJobs/*`
165 &quot;patchConfig&quot;: { # Patch configuration specifications. Contains details on how to apply the patch(es) to a VM instance. # Patch configuration being applied.
166 &quot;apt&quot;: { # Apt patching is completed by executing `apt-get update &amp;&amp; apt-get upgrade`. Additional options can be set to control how this is executed. # Apt update settings. Use this setting to override the default `apt` patch rules.
167 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages will be excluded
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700168 &quot;A String&quot;,
169 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800170 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800171 &quot;A String&quot;,
172 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800173 &quot;type&quot;: &quot;A String&quot;, # By changing the type to DIST, the patching is performed using `apt-get dist-upgrade` instead.
174 },
175 &quot;goo&quot;: { # Googet patching is performed by running `googet update`. # Goo update settings. Use this setting to override the default `goo` patch rules.
176 },
177 &quot;postStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run after the patch update.
178 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
179 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
180 42,
181 ],
182 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
183 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
184 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
185 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
186 },
187 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
188 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
189 },
190 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
191 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
192 42,
193 ],
194 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
195 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
196 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
197 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
198 },
199 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
200 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
201 },
202 },
203 &quot;preStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run before the patch update.
204 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
205 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
206 42,
207 ],
208 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
209 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
210 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
211 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
212 },
213 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
214 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
215 },
216 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
217 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
218 42,
219 ],
220 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
221 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
222 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
223 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
224 },
225 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
226 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
227 },
228 },
229 &quot;rebootConfig&quot;: &quot;A String&quot;, # Post-patch reboot settings.
230 &quot;windowsUpdate&quot;: { # Windows patching is performed using the Windows Update Agent. # Windows update settings. Use this override the default windows patch rules.
231 &quot;classifications&quot;: [ # Only apply updates of these windows update classifications. If empty, all updates are applied.
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800232 &quot;A String&quot;,
233 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800234 &quot;excludes&quot;: [ # List of KBs to exclude from update.
235 &quot;A String&quot;,
236 ],
237 &quot;exclusivePatches&quot;: [ # An exclusive list of kbs to be updated. These are the only patches that will be updated. This field must not be used with other patch configurations.
238 &quot;A String&quot;,
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700239 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800240 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800241 &quot;yum&quot;: { # Yum patching is performed by executing `yum update`. Additional options can be set to control how this is executed. Note that not all settings are supported on all platforms. # Yum update settings. Use this setting to override the default `yum` patch rules.
242 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages are excluded by using the yum `--exclude` flag.
243 &quot;A String&quot;,
244 ],
245 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field must not be specified with any other patch configuration fields.
246 &quot;A String&quot;,
247 ],
248 &quot;minimal&quot;: True or False, # Will cause patch to run `yum update-minimal` instead.
249 &quot;security&quot;: True or False, # Adds the `--security` flag to `yum update`. Not supported on all platforms.
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800250 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800251 &quot;zypper&quot;: { # Zypper patching is performed by running `zypper patch`. See also https://en.opensuse.org/SDB:Zypper_manual. # Zypper update settings. Use this setting to override the default `zypper` patch rules.
252 &quot;categories&quot;: [ # Install only patches with these categories. Common categories include security, recommended, and feature.
253 &quot;A String&quot;,
254 ],
255 &quot;excludes&quot;: [ # List of patches to exclude from update.
256 &quot;A String&quot;,
257 ],
258 &quot;exclusivePatches&quot;: [ # An exclusive list of patches to be updated. These are the only patches that will be installed using &#x27;zypper patch patch:&#x27; command. This field must not be used with any other patch configuration fields.
259 &quot;A String&quot;,
260 ],
261 &quot;severities&quot;: [ # Install only patches with these severities. Common severities include critical, important, moderate, and low.
262 &quot;A String&quot;,
263 ],
264 &quot;withOptional&quot;: True or False, # Adds the `--with-optional` flag to `zypper patch`.
265 &quot;withUpdate&quot;: True or False, # Adds the `--with-update` flag, to `zypper patch`.
266 },
267 },
268 &quot;patchDeployment&quot;: &quot;A String&quot;, # Output only. Name of the patch deployment that created this patch job.
269 &quot;percentComplete&quot;: 3.14, # Reflects the overall progress of the patch job in the range of 0.0 being no progress to 100.0 being complete.
270 &quot;rollout&quot;: { # Patch rollout configuration specifications. Contains details on the concurrency control when applying patch(es) to all targeted VMs. # Rollout strategy being applied.
271 &quot;disruptionBudget&quot;: { # Message encapsulating a value that can be either absolute (&quot;fixed&quot;) or relative (&quot;percent&quot;) to a value. # The maximum number (or percentage) of VMs per zone to disrupt at any given moment. The number of VMs calculated from multiplying the percentage by the total number of VMs in a zone is rounded up. During patching, a VM is considered disrupted from the time the agent is notified to begin until patching has completed. This disruption time includes the time to complete reboot and any post-patch steps. A VM contributes to the disruption budget if its patching operation fails either when applying the patches, running pre or post patch steps, or if it fails to respond with a success notification before timing out. VMs that are not running or do not have an active agent do not count toward this disruption budget. For zone-by-zone rollouts, if the disruption budget in a zone is exceeded, the patch job stops, because continuing to the next zone requires completion of the patch process in the previous zone. For example, if the disruption budget has a fixed value of `10`, and 8 VMs fail to patch in the current zone, the patch job continues to patch 2 VMs at a time until the zone is completed. When that zone is completed successfully, patching begins with 10 VMs at a time in the next zone. If 10 VMs in the next zone fail to patch, the patch job stops.
272 &quot;fixed&quot;: 42, # Specifies a fixed value.
273 &quot;percent&quot;: 42, # Specifies the relative value defined as a percentage, which will be multiplied by a reference value.
274 },
275 &quot;mode&quot;: &quot;A String&quot;, # Mode of the patch rollout.
276 },
277 &quot;state&quot;: &quot;A String&quot;, # The current state of the PatchJob.
278 &quot;updateTime&quot;: &quot;A String&quot;, # Last time this patch job was updated.
279}</pre>
Bu Sun Kim65020912020-05-20 12:08:20 -0700280</div>
281
282<div class="method">
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700283 <code class="details" id="close">close()</code>
284 <pre>Close httplib2 connections.</pre>
285</div>
286
287<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -0700288 <code class="details" id="execute">execute(parent, body=None, x__xgafv=None)</code>
289 <pre>Patch VM instances by creating and running a patch job.
290
291Args:
292 parent: string, Required. The project in which to run this patch in the form `projects/*` (required)
293 body: object, The request body.
294 The object takes the form of:
295
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700296{ # A request message to initiate patching across Compute Engine instances.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800297 &quot;description&quot;: &quot;A String&quot;, # Description of the patch job. Length of the description is limited to 1024 characters.
298 &quot;displayName&quot;: &quot;A String&quot;, # Display name for this patch job. This does not have to be unique.
299 &quot;dryRun&quot;: True or False, # If this patch is a dry-run only, instances are contacted but will do nothing.
300 &quot;duration&quot;: &quot;A String&quot;, # Duration of the patch job. After the duration ends, the patch job times out.
301 &quot;instanceFilter&quot;: { # A filter to target VM instances for patching. The targeted VMs must meet all criteria specified. So if both labels and zones are specified, the patch job targets only VMs with those labels and in those zones. # Required. Instances to patch, either explicitly or filtered by some criteria such as zone or labels.
302 &quot;all&quot;: True or False, # Target all VM instances in the project. If true, no other criteria is permitted.
303 &quot;groupLabels&quot;: [ # Targets VM instances matching ANY of these GroupLabels. This allows targeting of disparate groups of VM instances.
304 { # Targets a group of VM instances by using their [assigned labels](https://cloud.google.com/compute/docs/labeling-resources). Labels are key-value pairs. A `GroupLabel` is a combination of labels that is used to target VMs for a patch job. For example, a patch job can target VMs that have the following `GroupLabel`: `{&quot;env&quot;:&quot;test&quot;, &quot;app&quot;:&quot;web&quot;}`. This means that the patch job is applied to VMs that have both the labels `env=test` and `app=web`.
305 &quot;labels&quot;: { # Compute Engine instance labels that must be present for a VM instance to be targeted by this filter.
306 &quot;a_key&quot;: &quot;A String&quot;,
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800307 },
308 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800309 ],
310 &quot;instanceNamePrefixes&quot;: [ # Targets VMs whose name starts with one of these prefixes. Similar to labels, this is another way to group VMs when targeting configs, for example prefix=&quot;prod-&quot;.
311 &quot;A String&quot;,
312 ],
313 &quot;instances&quot;: [ # Targets any of the VM instances specified. Instances are specified by their URI in the form `zones/[ZONE]/instances/[INSTANCE_NAME]`, `projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`, or `https://www.googleapis.com/compute/v1/projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`
314 &quot;A String&quot;,
315 ],
316 &quot;zones&quot;: [ # Targets VM instances in ANY of these zones. Leave empty to target VM instances in any zone.
317 &quot;A String&quot;,
318 ],
319 },
320 &quot;patchConfig&quot;: { # Patch configuration specifications. Contains details on how to apply the patch(es) to a VM instance. # Patch configuration being applied. If omitted, instances are patched using the default configurations.
321 &quot;apt&quot;: { # Apt patching is completed by executing `apt-get update &amp;&amp; apt-get upgrade`. Additional options can be set to control how this is executed. # Apt update settings. Use this setting to override the default `apt` patch rules.
322 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages will be excluded
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800323 &quot;A String&quot;,
324 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800325 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800326 &quot;A String&quot;,
327 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800328 &quot;type&quot;: &quot;A String&quot;, # By changing the type to DIST, the patching is performed using `apt-get dist-upgrade` instead.
329 },
330 &quot;goo&quot;: { # Googet patching is performed by running `googet update`. # Goo update settings. Use this setting to override the default `goo` patch rules.
331 },
332 &quot;postStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run after the patch update.
333 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
334 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
335 42,
336 ],
337 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
338 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
339 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
340 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800341 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800342 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
343 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
344 },
345 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
346 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
347 42,
348 ],
349 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
350 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
351 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
352 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
353 },
354 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
355 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
356 },
357 },
358 &quot;preStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run before the patch update.
359 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
360 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
361 42,
362 ],
363 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
364 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
365 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
366 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
367 },
368 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
369 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
370 },
371 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
372 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
373 42,
374 ],
375 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
376 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
377 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
378 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
379 },
380 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
381 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
382 },
383 },
384 &quot;rebootConfig&quot;: &quot;A String&quot;, # Post-patch reboot settings.
385 &quot;windowsUpdate&quot;: { # Windows patching is performed using the Windows Update Agent. # Windows update settings. Use this override the default windows patch rules.
386 &quot;classifications&quot;: [ # Only apply updates of these windows update classifications. If empty, all updates are applied.
387 &quot;A String&quot;,
388 ],
389 &quot;excludes&quot;: [ # List of KBs to exclude from update.
390 &quot;A String&quot;,
391 ],
392 &quot;exclusivePatches&quot;: [ # An exclusive list of kbs to be updated. These are the only patches that will be updated. This field must not be used with other patch configurations.
393 &quot;A String&quot;,
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800394 ],
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800395 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800396 &quot;yum&quot;: { # Yum patching is performed by executing `yum update`. Additional options can be set to control how this is executed. Note that not all settings are supported on all platforms. # Yum update settings. Use this setting to override the default `yum` patch rules.
397 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages are excluded by using the yum `--exclude` flag.
398 &quot;A String&quot;,
399 ],
400 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field must not be specified with any other patch configuration fields.
401 &quot;A String&quot;,
402 ],
403 &quot;minimal&quot;: True or False, # Will cause patch to run `yum update-minimal` instead.
404 &quot;security&quot;: True or False, # Adds the `--security` flag to `yum update`. Not supported on all platforms.
405 },
406 &quot;zypper&quot;: { # Zypper patching is performed by running `zypper patch`. See also https://en.opensuse.org/SDB:Zypper_manual. # Zypper update settings. Use this setting to override the default `zypper` patch rules.
407 &quot;categories&quot;: [ # Install only patches with these categories. Common categories include security, recommended, and feature.
408 &quot;A String&quot;,
409 ],
410 &quot;excludes&quot;: [ # List of patches to exclude from update.
411 &quot;A String&quot;,
412 ],
413 &quot;exclusivePatches&quot;: [ # An exclusive list of patches to be updated. These are the only patches that will be installed using &#x27;zypper patch patch:&#x27; command. This field must not be used with any other patch configuration fields.
414 &quot;A String&quot;,
415 ],
416 &quot;severities&quot;: [ # Install only patches with these severities. Common severities include critical, important, moderate, and low.
417 &quot;A String&quot;,
418 ],
419 &quot;withOptional&quot;: True or False, # Adds the `--with-optional` flag to `zypper patch`.
420 &quot;withUpdate&quot;: True or False, # Adds the `--with-update` flag, to `zypper patch`.
421 },
422 },
423 &quot;rollout&quot;: { # Patch rollout configuration specifications. Contains details on the concurrency control when applying patch(es) to all targeted VMs. # Rollout strategy of the patch job.
424 &quot;disruptionBudget&quot;: { # Message encapsulating a value that can be either absolute (&quot;fixed&quot;) or relative (&quot;percent&quot;) to a value. # The maximum number (or percentage) of VMs per zone to disrupt at any given moment. The number of VMs calculated from multiplying the percentage by the total number of VMs in a zone is rounded up. During patching, a VM is considered disrupted from the time the agent is notified to begin until patching has completed. This disruption time includes the time to complete reboot and any post-patch steps. A VM contributes to the disruption budget if its patching operation fails either when applying the patches, running pre or post patch steps, or if it fails to respond with a success notification before timing out. VMs that are not running or do not have an active agent do not count toward this disruption budget. For zone-by-zone rollouts, if the disruption budget in a zone is exceeded, the patch job stops, because continuing to the next zone requires completion of the patch process in the previous zone. For example, if the disruption budget has a fixed value of `10`, and 8 VMs fail to patch in the current zone, the patch job continues to patch 2 VMs at a time until the zone is completed. When that zone is completed successfully, patching begins with 10 VMs at a time in the next zone. If 10 VMs in the next zone fail to patch, the patch job stops.
425 &quot;fixed&quot;: 42, # Specifies a fixed value.
426 &quot;percent&quot;: 42, # Specifies the relative value defined as a percentage, which will be multiplied by a reference value.
427 },
428 &quot;mode&quot;: &quot;A String&quot;, # Mode of the patch rollout.
429 },
430}
Bu Sun Kim65020912020-05-20 12:08:20 -0700431
432 x__xgafv: string, V1 error format.
433 Allowed values
434 1 - v1 error format
435 2 - v2 error format
436
437Returns:
438 An object of the form:
439
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700440 { # A high level representation of a patch job that is either in progress or has completed. Instance details are not included in the job. To paginate through instance details, use ListPatchJobInstanceDetails. For more information about patch jobs, see [Creating patch jobs](https://cloud.google.com/compute/docs/os-patch-management/create-patch-job).
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800441 &quot;createTime&quot;: &quot;A String&quot;, # Time this patch job was created.
442 &quot;description&quot;: &quot;A String&quot;, # Description of the patch job. Length of the description is limited to 1024 characters.
443 &quot;displayName&quot;: &quot;A String&quot;, # Display name for this patch job. This is not a unique identifier.
444 &quot;dryRun&quot;: True or False, # If this patch job is a dry run, the agent reports that it has finished without running any updates on the VM instance.
445 &quot;duration&quot;: &quot;A String&quot;, # Duration of the patch job. After the duration ends, the patch job times out.
446 &quot;errorMessage&quot;: &quot;A String&quot;, # If this patch job failed, this message provides information about the failure.
447 &quot;instanceDetailsSummary&quot;: { # A summary of the current patch state across all instances that this patch job affects. Contains counts of instances in different states. These states map to `InstancePatchState`. List patch job instance details to see the specific states of each instance. # Summary of instance details.
448 &quot;ackedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have acked and will start shortly.
449 &quot;applyingPatchesInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are applying patches.
450 &quot;downloadingPatchesInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are downloading patches.
451 &quot;failedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that failed.
452 &quot;inactiveInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are inactive.
453 &quot;noAgentDetectedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that do not appear to be running the agent. Check to ensure that the agent is installed, running, and able to communicate with the service.
454 &quot;notifiedInstanceCount&quot;: &quot;A String&quot;, # Number of instances notified about patch job.
455 &quot;pendingInstanceCount&quot;: &quot;A String&quot;, # Number of instances pending patch job.
456 &quot;postPatchStepInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are running the post-patch step.
457 &quot;prePatchStepInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are running the pre-patch step.
458 &quot;rebootingInstanceCount&quot;: &quot;A String&quot;, # Number of instances rebooting.
459 &quot;startedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have started.
460 &quot;succeededInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have completed successfully.
461 &quot;succeededRebootRequiredInstanceCount&quot;: &quot;A String&quot;, # Number of instances that require reboot.
462 &quot;timedOutInstanceCount&quot;: &quot;A String&quot;, # Number of instances that exceeded the time out while applying the patch.
463 },
464 &quot;instanceFilter&quot;: { # A filter to target VM instances for patching. The targeted VMs must meet all criteria specified. So if both labels and zones are specified, the patch job targets only VMs with those labels and in those zones. # Instances to patch.
465 &quot;all&quot;: True or False, # Target all VM instances in the project. If true, no other criteria is permitted.
466 &quot;groupLabels&quot;: [ # Targets VM instances matching ANY of these GroupLabels. This allows targeting of disparate groups of VM instances.
467 { # Targets a group of VM instances by using their [assigned labels](https://cloud.google.com/compute/docs/labeling-resources). Labels are key-value pairs. A `GroupLabel` is a combination of labels that is used to target VMs for a patch job. For example, a patch job can target VMs that have the following `GroupLabel`: `{&quot;env&quot;:&quot;test&quot;, &quot;app&quot;:&quot;web&quot;}`. This means that the patch job is applied to VMs that have both the labels `env=test` and `app=web`.
468 &quot;labels&quot;: { # Compute Engine instance labels that must be present for a VM instance to be targeted by this filter.
469 &quot;a_key&quot;: &quot;A String&quot;,
470 },
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800471 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800472 ],
473 &quot;instanceNamePrefixes&quot;: [ # Targets VMs whose name starts with one of these prefixes. Similar to labels, this is another way to group VMs when targeting configs, for example prefix=&quot;prod-&quot;.
474 &quot;A String&quot;,
475 ],
476 &quot;instances&quot;: [ # Targets any of the VM instances specified. Instances are specified by their URI in the form `zones/[ZONE]/instances/[INSTANCE_NAME]`, `projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`, or `https://www.googleapis.com/compute/v1/projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`
477 &quot;A String&quot;,
478 ],
479 &quot;zones&quot;: [ # Targets VM instances in ANY of these zones. Leave empty to target VM instances in any zone.
480 &quot;A String&quot;,
481 ],
482 },
483 &quot;name&quot;: &quot;A String&quot;, # Unique identifier for this patch job in the form `projects/*/patchJobs/*`
484 &quot;patchConfig&quot;: { # Patch configuration specifications. Contains details on how to apply the patch(es) to a VM instance. # Patch configuration being applied.
485 &quot;apt&quot;: { # Apt patching is completed by executing `apt-get update &amp;&amp; apt-get upgrade`. Additional options can be set to control how this is executed. # Apt update settings. Use this setting to override the default `apt` patch rules.
486 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages will be excluded
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700487 &quot;A String&quot;,
488 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800489 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800490 &quot;A String&quot;,
491 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800492 &quot;type&quot;: &quot;A String&quot;, # By changing the type to DIST, the patching is performed using `apt-get dist-upgrade` instead.
493 },
494 &quot;goo&quot;: { # Googet patching is performed by running `googet update`. # Goo update settings. Use this setting to override the default `goo` patch rules.
495 },
496 &quot;postStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run after the patch update.
497 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
498 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
499 42,
500 ],
501 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
502 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
503 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
504 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
505 },
506 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
507 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
508 },
509 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
510 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
511 42,
512 ],
513 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
514 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
515 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
516 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
517 },
518 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
519 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
520 },
521 },
522 &quot;preStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run before the patch update.
523 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
524 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
525 42,
526 ],
527 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
528 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
529 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
530 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
531 },
532 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
533 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
534 },
535 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
536 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
537 42,
538 ],
539 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
540 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
541 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
542 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
543 },
544 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
545 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
546 },
547 },
548 &quot;rebootConfig&quot;: &quot;A String&quot;, # Post-patch reboot settings.
549 &quot;windowsUpdate&quot;: { # Windows patching is performed using the Windows Update Agent. # Windows update settings. Use this override the default windows patch rules.
550 &quot;classifications&quot;: [ # Only apply updates of these windows update classifications. If empty, all updates are applied.
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800551 &quot;A String&quot;,
552 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800553 &quot;excludes&quot;: [ # List of KBs to exclude from update.
554 &quot;A String&quot;,
555 ],
556 &quot;exclusivePatches&quot;: [ # An exclusive list of kbs to be updated. These are the only patches that will be updated. This field must not be used with other patch configurations.
557 &quot;A String&quot;,
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700558 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800559 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800560 &quot;yum&quot;: { # Yum patching is performed by executing `yum update`. Additional options can be set to control how this is executed. Note that not all settings are supported on all platforms. # Yum update settings. Use this setting to override the default `yum` patch rules.
561 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages are excluded by using the yum `--exclude` flag.
562 &quot;A String&quot;,
563 ],
564 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field must not be specified with any other patch configuration fields.
565 &quot;A String&quot;,
566 ],
567 &quot;minimal&quot;: True or False, # Will cause patch to run `yum update-minimal` instead.
568 &quot;security&quot;: True or False, # Adds the `--security` flag to `yum update`. Not supported on all platforms.
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800569 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800570 &quot;zypper&quot;: { # Zypper patching is performed by running `zypper patch`. See also https://en.opensuse.org/SDB:Zypper_manual. # Zypper update settings. Use this setting to override the default `zypper` patch rules.
571 &quot;categories&quot;: [ # Install only patches with these categories. Common categories include security, recommended, and feature.
572 &quot;A String&quot;,
573 ],
574 &quot;excludes&quot;: [ # List of patches to exclude from update.
575 &quot;A String&quot;,
576 ],
577 &quot;exclusivePatches&quot;: [ # An exclusive list of patches to be updated. These are the only patches that will be installed using &#x27;zypper patch patch:&#x27; command. This field must not be used with any other patch configuration fields.
578 &quot;A String&quot;,
579 ],
580 &quot;severities&quot;: [ # Install only patches with these severities. Common severities include critical, important, moderate, and low.
581 &quot;A String&quot;,
582 ],
583 &quot;withOptional&quot;: True or False, # Adds the `--with-optional` flag to `zypper patch`.
584 &quot;withUpdate&quot;: True or False, # Adds the `--with-update` flag, to `zypper patch`.
585 },
586 },
587 &quot;patchDeployment&quot;: &quot;A String&quot;, # Output only. Name of the patch deployment that created this patch job.
588 &quot;percentComplete&quot;: 3.14, # Reflects the overall progress of the patch job in the range of 0.0 being no progress to 100.0 being complete.
589 &quot;rollout&quot;: { # Patch rollout configuration specifications. Contains details on the concurrency control when applying patch(es) to all targeted VMs. # Rollout strategy being applied.
590 &quot;disruptionBudget&quot;: { # Message encapsulating a value that can be either absolute (&quot;fixed&quot;) or relative (&quot;percent&quot;) to a value. # The maximum number (or percentage) of VMs per zone to disrupt at any given moment. The number of VMs calculated from multiplying the percentage by the total number of VMs in a zone is rounded up. During patching, a VM is considered disrupted from the time the agent is notified to begin until patching has completed. This disruption time includes the time to complete reboot and any post-patch steps. A VM contributes to the disruption budget if its patching operation fails either when applying the patches, running pre or post patch steps, or if it fails to respond with a success notification before timing out. VMs that are not running or do not have an active agent do not count toward this disruption budget. For zone-by-zone rollouts, if the disruption budget in a zone is exceeded, the patch job stops, because continuing to the next zone requires completion of the patch process in the previous zone. For example, if the disruption budget has a fixed value of `10`, and 8 VMs fail to patch in the current zone, the patch job continues to patch 2 VMs at a time until the zone is completed. When that zone is completed successfully, patching begins with 10 VMs at a time in the next zone. If 10 VMs in the next zone fail to patch, the patch job stops.
591 &quot;fixed&quot;: 42, # Specifies a fixed value.
592 &quot;percent&quot;: 42, # Specifies the relative value defined as a percentage, which will be multiplied by a reference value.
593 },
594 &quot;mode&quot;: &quot;A String&quot;, # Mode of the patch rollout.
595 },
596 &quot;state&quot;: &quot;A String&quot;, # The current state of the PatchJob.
597 &quot;updateTime&quot;: &quot;A String&quot;, # Last time this patch job was updated.
598}</pre>
Bu Sun Kim65020912020-05-20 12:08:20 -0700599</div>
600
601<div class="method">
602 <code class="details" id="get">get(name, x__xgafv=None)</code>
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700603 <pre>Get the patch job. This can be used to track the progress of an ongoing patch job or review the details of completed jobs.
Bu Sun Kim65020912020-05-20 12:08:20 -0700604
605Args:
606 name: string, Required. Name of the patch in the form `projects/*/patchJobs/*` (required)
607 x__xgafv: string, V1 error format.
608 Allowed values
609 1 - v1 error format
610 2 - v2 error format
611
612Returns:
613 An object of the form:
614
Dmitry Frenkel3e17f892020-10-06 16:46:05 -0700615 { # A high level representation of a patch job that is either in progress or has completed. Instance details are not included in the job. To paginate through instance details, use ListPatchJobInstanceDetails. For more information about patch jobs, see [Creating patch jobs](https://cloud.google.com/compute/docs/os-patch-management/create-patch-job).
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800616 &quot;createTime&quot;: &quot;A String&quot;, # Time this patch job was created.
617 &quot;description&quot;: &quot;A String&quot;, # Description of the patch job. Length of the description is limited to 1024 characters.
618 &quot;displayName&quot;: &quot;A String&quot;, # Display name for this patch job. This is not a unique identifier.
619 &quot;dryRun&quot;: True or False, # If this patch job is a dry run, the agent reports that it has finished without running any updates on the VM instance.
620 &quot;duration&quot;: &quot;A String&quot;, # Duration of the patch job. After the duration ends, the patch job times out.
621 &quot;errorMessage&quot;: &quot;A String&quot;, # If this patch job failed, this message provides information about the failure.
622 &quot;instanceDetailsSummary&quot;: { # A summary of the current patch state across all instances that this patch job affects. Contains counts of instances in different states. These states map to `InstancePatchState`. List patch job instance details to see the specific states of each instance. # Summary of instance details.
623 &quot;ackedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have acked and will start shortly.
624 &quot;applyingPatchesInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are applying patches.
625 &quot;downloadingPatchesInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are downloading patches.
626 &quot;failedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that failed.
627 &quot;inactiveInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are inactive.
628 &quot;noAgentDetectedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that do not appear to be running the agent. Check to ensure that the agent is installed, running, and able to communicate with the service.
629 &quot;notifiedInstanceCount&quot;: &quot;A String&quot;, # Number of instances notified about patch job.
630 &quot;pendingInstanceCount&quot;: &quot;A String&quot;, # Number of instances pending patch job.
631 &quot;postPatchStepInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are running the post-patch step.
632 &quot;prePatchStepInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are running the pre-patch step.
633 &quot;rebootingInstanceCount&quot;: &quot;A String&quot;, # Number of instances rebooting.
634 &quot;startedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have started.
635 &quot;succeededInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have completed successfully.
636 &quot;succeededRebootRequiredInstanceCount&quot;: &quot;A String&quot;, # Number of instances that require reboot.
637 &quot;timedOutInstanceCount&quot;: &quot;A String&quot;, # Number of instances that exceeded the time out while applying the patch.
638 },
639 &quot;instanceFilter&quot;: { # A filter to target VM instances for patching. The targeted VMs must meet all criteria specified. So if both labels and zones are specified, the patch job targets only VMs with those labels and in those zones. # Instances to patch.
640 &quot;all&quot;: True or False, # Target all VM instances in the project. If true, no other criteria is permitted.
641 &quot;groupLabels&quot;: [ # Targets VM instances matching ANY of these GroupLabels. This allows targeting of disparate groups of VM instances.
642 { # Targets a group of VM instances by using their [assigned labels](https://cloud.google.com/compute/docs/labeling-resources). Labels are key-value pairs. A `GroupLabel` is a combination of labels that is used to target VMs for a patch job. For example, a patch job can target VMs that have the following `GroupLabel`: `{&quot;env&quot;:&quot;test&quot;, &quot;app&quot;:&quot;web&quot;}`. This means that the patch job is applied to VMs that have both the labels `env=test` and `app=web`.
643 &quot;labels&quot;: { # Compute Engine instance labels that must be present for a VM instance to be targeted by this filter.
644 &quot;a_key&quot;: &quot;A String&quot;,
645 },
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800646 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800647 ],
648 &quot;instanceNamePrefixes&quot;: [ # Targets VMs whose name starts with one of these prefixes. Similar to labels, this is another way to group VMs when targeting configs, for example prefix=&quot;prod-&quot;.
649 &quot;A String&quot;,
650 ],
651 &quot;instances&quot;: [ # Targets any of the VM instances specified. Instances are specified by their URI in the form `zones/[ZONE]/instances/[INSTANCE_NAME]`, `projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`, or `https://www.googleapis.com/compute/v1/projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`
652 &quot;A String&quot;,
653 ],
654 &quot;zones&quot;: [ # Targets VM instances in ANY of these zones. Leave empty to target VM instances in any zone.
655 &quot;A String&quot;,
656 ],
657 },
658 &quot;name&quot;: &quot;A String&quot;, # Unique identifier for this patch job in the form `projects/*/patchJobs/*`
659 &quot;patchConfig&quot;: { # Patch configuration specifications. Contains details on how to apply the patch(es) to a VM instance. # Patch configuration being applied.
660 &quot;apt&quot;: { # Apt patching is completed by executing `apt-get update &amp;&amp; apt-get upgrade`. Additional options can be set to control how this is executed. # Apt update settings. Use this setting to override the default `apt` patch rules.
661 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages will be excluded
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700662 &quot;A String&quot;,
663 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800664 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800665 &quot;A String&quot;,
666 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800667 &quot;type&quot;: &quot;A String&quot;, # By changing the type to DIST, the patching is performed using `apt-get dist-upgrade` instead.
668 },
669 &quot;goo&quot;: { # Googet patching is performed by running `googet update`. # Goo update settings. Use this setting to override the default `goo` patch rules.
670 },
671 &quot;postStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run after the patch update.
672 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
673 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
674 42,
675 ],
676 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
677 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
678 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
679 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
680 },
681 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
682 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
683 },
684 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
685 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
686 42,
687 ],
688 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
689 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
690 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
691 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
692 },
693 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
694 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
695 },
696 },
697 &quot;preStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run before the patch update.
698 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
699 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
700 42,
701 ],
702 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
703 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
704 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
705 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
706 },
707 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
708 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
709 },
710 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
711 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
712 42,
713 ],
714 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
715 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
716 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
717 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
718 },
719 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
720 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
721 },
722 },
723 &quot;rebootConfig&quot;: &quot;A String&quot;, # Post-patch reboot settings.
724 &quot;windowsUpdate&quot;: { # Windows patching is performed using the Windows Update Agent. # Windows update settings. Use this override the default windows patch rules.
725 &quot;classifications&quot;: [ # Only apply updates of these windows update classifications. If empty, all updates are applied.
Yoshi Automation Bot0d561ef2020-11-25 07:50:41 -0800726 &quot;A String&quot;,
727 ],
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800728 &quot;excludes&quot;: [ # List of KBs to exclude from update.
729 &quot;A String&quot;,
730 ],
731 &quot;exclusivePatches&quot;: [ # An exclusive list of kbs to be updated. These are the only patches that will be updated. This field must not be used with other patch configurations.
732 &quot;A String&quot;,
Bu Sun Kim673ec5c2020-11-16 11:05:03 -0700733 ],
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800734 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800735 &quot;yum&quot;: { # Yum patching is performed by executing `yum update`. Additional options can be set to control how this is executed. Note that not all settings are supported on all platforms. # Yum update settings. Use this setting to override the default `yum` patch rules.
736 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages are excluded by using the yum `--exclude` flag.
737 &quot;A String&quot;,
738 ],
739 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field must not be specified with any other patch configuration fields.
740 &quot;A String&quot;,
741 ],
742 &quot;minimal&quot;: True or False, # Will cause patch to run `yum update-minimal` instead.
743 &quot;security&quot;: True or False, # Adds the `--security` flag to `yum update`. Not supported on all platforms.
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800744 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800745 &quot;zypper&quot;: { # Zypper patching is performed by running `zypper patch`. See also https://en.opensuse.org/SDB:Zypper_manual. # Zypper update settings. Use this setting to override the default `zypper` patch rules.
746 &quot;categories&quot;: [ # Install only patches with these categories. Common categories include security, recommended, and feature.
747 &quot;A String&quot;,
748 ],
749 &quot;excludes&quot;: [ # List of patches to exclude from update.
750 &quot;A String&quot;,
751 ],
752 &quot;exclusivePatches&quot;: [ # An exclusive list of patches to be updated. These are the only patches that will be installed using &#x27;zypper patch patch:&#x27; command. This field must not be used with any other patch configuration fields.
753 &quot;A String&quot;,
754 ],
755 &quot;severities&quot;: [ # Install only patches with these severities. Common severities include critical, important, moderate, and low.
756 &quot;A String&quot;,
757 ],
758 &quot;withOptional&quot;: True or False, # Adds the `--with-optional` flag to `zypper patch`.
759 &quot;withUpdate&quot;: True or False, # Adds the `--with-update` flag, to `zypper patch`.
760 },
761 },
762 &quot;patchDeployment&quot;: &quot;A String&quot;, # Output only. Name of the patch deployment that created this patch job.
763 &quot;percentComplete&quot;: 3.14, # Reflects the overall progress of the patch job in the range of 0.0 being no progress to 100.0 being complete.
764 &quot;rollout&quot;: { # Patch rollout configuration specifications. Contains details on the concurrency control when applying patch(es) to all targeted VMs. # Rollout strategy being applied.
765 &quot;disruptionBudget&quot;: { # Message encapsulating a value that can be either absolute (&quot;fixed&quot;) or relative (&quot;percent&quot;) to a value. # The maximum number (or percentage) of VMs per zone to disrupt at any given moment. The number of VMs calculated from multiplying the percentage by the total number of VMs in a zone is rounded up. During patching, a VM is considered disrupted from the time the agent is notified to begin until patching has completed. This disruption time includes the time to complete reboot and any post-patch steps. A VM contributes to the disruption budget if its patching operation fails either when applying the patches, running pre or post patch steps, or if it fails to respond with a success notification before timing out. VMs that are not running or do not have an active agent do not count toward this disruption budget. For zone-by-zone rollouts, if the disruption budget in a zone is exceeded, the patch job stops, because continuing to the next zone requires completion of the patch process in the previous zone. For example, if the disruption budget has a fixed value of `10`, and 8 VMs fail to patch in the current zone, the patch job continues to patch 2 VMs at a time until the zone is completed. When that zone is completed successfully, patching begins with 10 VMs at a time in the next zone. If 10 VMs in the next zone fail to patch, the patch job stops.
766 &quot;fixed&quot;: 42, # Specifies a fixed value.
767 &quot;percent&quot;: 42, # Specifies the relative value defined as a percentage, which will be multiplied by a reference value.
768 },
769 &quot;mode&quot;: &quot;A String&quot;, # Mode of the patch rollout.
770 },
771 &quot;state&quot;: &quot;A String&quot;, # The current state of the PatchJob.
772 &quot;updateTime&quot;: &quot;A String&quot;, # Last time this patch job was updated.
773}</pre>
Bu Sun Kim65020912020-05-20 12:08:20 -0700774</div>
775
776<div class="method">
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800777 <code class="details" id="list">list(parent, filter=None, pageSize=None, pageToken=None, x__xgafv=None)</code>
Bu Sun Kim65020912020-05-20 12:08:20 -0700778 <pre>Get a list of patch jobs.
779
780Args:
781 parent: string, Required. In the form of `projects/*` (required)
Yoshi Automation Botb6971b02020-11-26 17:16:03 -0800782 filter: string, If provided, this field specifies the criteria that must be met by patch jobs to be included in the response. Currently, filtering is only available on the patch_deployment field.
Yoshi Automation Bot0bf565c2020-12-09 08:56:03 -0800783 pageSize: integer, The maximum number of instance status to return.
Yoshi Automation Botc2228be2020-11-24 15:48:03 -0800784 pageToken: string, A pagination token returned from a previous call that indicates where this listing should continue from.
Bu Sun Kim65020912020-05-20 12:08:20 -0700785 x__xgafv: string, V1 error format.
786 Allowed values
787 1 - v1 error format
788 2 - v2 error format
789
790Returns:
791 An object of the form:
792
793 { # A response message for listing patch jobs.
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800794 &quot;nextPageToken&quot;: &quot;A String&quot;, # A pagination token that can be used to get the next page of results.
795 &quot;patchJobs&quot;: [ # The list of patch jobs.
796 { # A high level representation of a patch job that is either in progress or has completed. Instance details are not included in the job. To paginate through instance details, use ListPatchJobInstanceDetails. For more information about patch jobs, see [Creating patch jobs](https://cloud.google.com/compute/docs/os-patch-management/create-patch-job).
797 &quot;createTime&quot;: &quot;A String&quot;, # Time this patch job was created.
798 &quot;description&quot;: &quot;A String&quot;, # Description of the patch job. Length of the description is limited to 1024 characters.
799 &quot;displayName&quot;: &quot;A String&quot;, # Display name for this patch job. This is not a unique identifier.
800 &quot;dryRun&quot;: True or False, # If this patch job is a dry run, the agent reports that it has finished without running any updates on the VM instance.
801 &quot;duration&quot;: &quot;A String&quot;, # Duration of the patch job. After the duration ends, the patch job times out.
802 &quot;errorMessage&quot;: &quot;A String&quot;, # If this patch job failed, this message provides information about the failure.
803 &quot;instanceDetailsSummary&quot;: { # A summary of the current patch state across all instances that this patch job affects. Contains counts of instances in different states. These states map to `InstancePatchState`. List patch job instance details to see the specific states of each instance. # Summary of instance details.
804 &quot;ackedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have acked and will start shortly.
805 &quot;applyingPatchesInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are applying patches.
806 &quot;downloadingPatchesInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are downloading patches.
807 &quot;failedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that failed.
808 &quot;inactiveInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are inactive.
809 &quot;noAgentDetectedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that do not appear to be running the agent. Check to ensure that the agent is installed, running, and able to communicate with the service.
810 &quot;notifiedInstanceCount&quot;: &quot;A String&quot;, # Number of instances notified about patch job.
811 &quot;pendingInstanceCount&quot;: &quot;A String&quot;, # Number of instances pending patch job.
812 &quot;postPatchStepInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are running the post-patch step.
813 &quot;prePatchStepInstanceCount&quot;: &quot;A String&quot;, # Number of instances that are running the pre-patch step.
814 &quot;rebootingInstanceCount&quot;: &quot;A String&quot;, # Number of instances rebooting.
815 &quot;startedInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have started.
816 &quot;succeededInstanceCount&quot;: &quot;A String&quot;, # Number of instances that have completed successfully.
817 &quot;succeededRebootRequiredInstanceCount&quot;: &quot;A String&quot;, # Number of instances that require reboot.
818 &quot;timedOutInstanceCount&quot;: &quot;A String&quot;, # Number of instances that exceeded the time out while applying the patch.
Bu Sun Kim65020912020-05-20 12:08:20 -0700819 },
Yoshi Automation Botcc94ec82021-01-15 07:10:04 -0800820 &quot;instanceFilter&quot;: { # A filter to target VM instances for patching. The targeted VMs must meet all criteria specified. So if both labels and zones are specified, the patch job targets only VMs with those labels and in those zones. # Instances to patch.
821 &quot;all&quot;: True or False, # Target all VM instances in the project. If true, no other criteria is permitted.
822 &quot;groupLabels&quot;: [ # Targets VM instances matching ANY of these GroupLabels. This allows targeting of disparate groups of VM instances.
823 { # Targets a group of VM instances by using their [assigned labels](https://cloud.google.com/compute/docs/labeling-resources). Labels are key-value pairs. A `GroupLabel` is a combination of labels that is used to target VMs for a patch job. For example, a patch job can target VMs that have the following `GroupLabel`: `{&quot;env&quot;:&quot;test&quot;, &quot;app&quot;:&quot;web&quot;}`. This means that the patch job is applied to VMs that have both the labels `env=test` and `app=web`.
824 &quot;labels&quot;: { # Compute Engine instance labels that must be present for a VM instance to be targeted by this filter.
825 &quot;a_key&quot;: &quot;A String&quot;,
826 },
827 },
828 ],
829 &quot;instanceNamePrefixes&quot;: [ # Targets VMs whose name starts with one of these prefixes. Similar to labels, this is another way to group VMs when targeting configs, for example prefix=&quot;prod-&quot;.
830 &quot;A String&quot;,
831 ],
832 &quot;instances&quot;: [ # Targets any of the VM instances specified. Instances are specified by their URI in the form `zones/[ZONE]/instances/[INSTANCE_NAME]`, `projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`, or `https://www.googleapis.com/compute/v1/projects/[PROJECT_ID]/zones/[ZONE]/instances/[INSTANCE_NAME]`
833 &quot;A String&quot;,
834 ],
835 &quot;zones&quot;: [ # Targets VM instances in ANY of these zones. Leave empty to target VM instances in any zone.
836 &quot;A String&quot;,
837 ],
838 },
839 &quot;name&quot;: &quot;A String&quot;, # Unique identifier for this patch job in the form `projects/*/patchJobs/*`
840 &quot;patchConfig&quot;: { # Patch configuration specifications. Contains details on how to apply the patch(es) to a VM instance. # Patch configuration being applied.
841 &quot;apt&quot;: { # Apt patching is completed by executing `apt-get update &amp;&amp; apt-get upgrade`. Additional options can be set to control how this is executed. # Apt update settings. Use this setting to override the default `apt` patch rules.
842 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages will be excluded
843 &quot;A String&quot;,
844 ],
845 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field cannot be specified with any other patch configuration fields.
846 &quot;A String&quot;,
847 ],
848 &quot;type&quot;: &quot;A String&quot;, # By changing the type to DIST, the patching is performed using `apt-get dist-upgrade` instead.
849 },
850 &quot;goo&quot;: { # Googet patching is performed by running `googet update`. # Goo update settings. Use this setting to override the default `goo` patch rules.
851 },
852 &quot;postStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run after the patch update.
853 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
854 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
855 42,
856 ],
857 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
858 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
859 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
860 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
861 },
862 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
863 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
864 },
865 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
866 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
867 42,
868 ],
869 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
870 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
871 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
872 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
873 },
874 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
875 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
876 },
877 },
878 &quot;preStep&quot;: { # A step that runs an executable for a PatchJob. # The `ExecStep` to run before the patch update.
879 &quot;linuxExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Linux VMs targeted by the PatchJob.
880 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
881 42,
882 ],
883 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
884 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
885 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
886 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
887 },
888 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
889 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
890 },
891 &quot;windowsExecStepConfig&quot;: { # Common configurations for an ExecStep. # The ExecStepConfig for all Windows VMs targeted by the PatchJob.
892 &quot;allowedSuccessCodes&quot;: [ # Defaults to [0]. A list of possible return values that the execution can return to indicate a success.
893 42,
894 ],
895 &quot;gcsObject&quot;: { # Cloud Storage object representation. # A Cloud Storage object containing the executable.
896 &quot;bucket&quot;: &quot;A String&quot;, # Required. Bucket of the Cloud Storage object.
897 &quot;generationNumber&quot;: &quot;A String&quot;, # Required. Generation number of the Cloud Storage object. This is used to ensure that the ExecStep specified by this PatchJob does not change.
898 &quot;object&quot;: &quot;A String&quot;, # Required. Name of the Cloud Storage object.
899 },
900 &quot;interpreter&quot;: &quot;A String&quot;, # The script interpreter to use to run the script. If no interpreter is specified the script will be executed directly, which will likely only succeed for scripts with [shebang lines] (https://en.wikipedia.org/wiki/Shebang_\(Unix\)).
901 &quot;localPath&quot;: &quot;A String&quot;, # An absolute path to the executable on the VM.
902 },
903 },
904 &quot;rebootConfig&quot;: &quot;A String&quot;, # Post-patch reboot settings.
905 &quot;windowsUpdate&quot;: { # Windows patching is performed using the Windows Update Agent. # Windows update settings. Use this override the default windows patch rules.
906 &quot;classifications&quot;: [ # Only apply updates of these windows update classifications. If empty, all updates are applied.
907 &quot;A String&quot;,
908 ],
909 &quot;excludes&quot;: [ # List of KBs to exclude from update.
910 &quot;A String&quot;,
911 ],
912 &quot;exclusivePatches&quot;: [ # An exclusive list of kbs to be updated. These are the only patches that will be updated. This field must not be used with other patch configurations.
913 &quot;A String&quot;,
914 ],
915 },
916 &quot;yum&quot;: { # Yum patching is performed by executing `yum update`. Additional options can be set to control how this is executed. Note that not all settings are supported on all platforms. # Yum update settings. Use this setting to override the default `yum` patch rules.
917 &quot;excludes&quot;: [ # List of packages to exclude from update. These packages are excluded by using the yum `--exclude` flag.
918 &quot;A String&quot;,
919 ],
920 &quot;exclusivePackages&quot;: [ # An exclusive list of packages to be updated. These are the only packages that will be updated. If these packages are not installed, they will be ignored. This field must not be specified with any other patch configuration fields.
921 &quot;A String&quot;,
922 ],
923 &quot;minimal&quot;: True or False, # Will cause patch to run `yum update-minimal` instead.
924 &quot;security&quot;: True or False, # Adds the `--security` flag to `yum update`. Not supported on all platforms.
925 },
926 &quot;zypper&quot;: { # Zypper patching is performed by running `zypper patch`. See also https://en.opensuse.org/SDB:Zypper_manual. # Zypper update settings. Use this setting to override the default `zypper` patch rules.
927 &quot;categories&quot;: [ # Install only patches with these categories. Common categories include security, recommended, and feature.
928 &quot;A String&quot;,
929 ],
930 &quot;excludes&quot;: [ # List of patches to exclude from update.
931 &quot;A String&quot;,
932 ],
933 &quot;exclusivePatches&quot;: [ # An exclusive list of patches to be updated. These are the only patches that will be installed using &#x27;zypper patch patch:&#x27; command. This field must not be used with any other patch configuration fields.
934 &quot;A String&quot;,
935 ],
936 &quot;severities&quot;: [ # Install only patches with these severities. Common severities include critical, important, moderate, and low.
937 &quot;A String&quot;,
938 ],
939 &quot;withOptional&quot;: True or False, # Adds the `--with-optional` flag to `zypper patch`.
940 &quot;withUpdate&quot;: True or False, # Adds the `--with-update` flag, to `zypper patch`.
941 },
942 },
943 &quot;patchDeployment&quot;: &quot;A String&quot;, # Output only. Name of the patch deployment that created this patch job.
944 &quot;percentComplete&quot;: 3.14, # Reflects the overall progress of the patch job in the range of 0.0 being no progress to 100.0 being complete.
945 &quot;rollout&quot;: { # Patch rollout configuration specifications. Contains details on the concurrency control when applying patch(es) to all targeted VMs. # Rollout strategy being applied.
946 &quot;disruptionBudget&quot;: { # Message encapsulating a value that can be either absolute (&quot;fixed&quot;) or relative (&quot;percent&quot;) to a value. # The maximum number (or percentage) of VMs per zone to disrupt at any given moment. The number of VMs calculated from multiplying the percentage by the total number of VMs in a zone is rounded up. During patching, a VM is considered disrupted from the time the agent is notified to begin until patching has completed. This disruption time includes the time to complete reboot and any post-patch steps. A VM contributes to the disruption budget if its patching operation fails either when applying the patches, running pre or post patch steps, or if it fails to respond with a success notification before timing out. VMs that are not running or do not have an active agent do not count toward this disruption budget. For zone-by-zone rollouts, if the disruption budget in a zone is exceeded, the patch job stops, because continuing to the next zone requires completion of the patch process in the previous zone. For example, if the disruption budget has a fixed value of `10`, and 8 VMs fail to patch in the current zone, the patch job continues to patch 2 VMs at a time until the zone is completed. When that zone is completed successfully, patching begins with 10 VMs at a time in the next zone. If 10 VMs in the next zone fail to patch, the patch job stops.
947 &quot;fixed&quot;: 42, # Specifies a fixed value.
948 &quot;percent&quot;: 42, # Specifies the relative value defined as a percentage, which will be multiplied by a reference value.
949 },
950 &quot;mode&quot;: &quot;A String&quot;, # Mode of the patch rollout.
951 },
952 &quot;state&quot;: &quot;A String&quot;, # The current state of the PatchJob.
953 &quot;updateTime&quot;: &quot;A String&quot;, # Last time this patch job was updated.
954 },
955 ],
956}</pre>
Bu Sun Kim65020912020-05-20 12:08:20 -0700957</div>
958
959<div class="method">
960 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
961 <pre>Retrieves the next page of results.
962
963Args:
964 previous_request: The request for the previous page. (required)
965 previous_response: The response from the request for the previous page. (required)
966
967Returns:
968 A request object that you can call &#x27;execute()&#x27; on to request the next
969 page. Returns None if there are no more items in the collection.
970 </pre>
971</div>
972
973</body></html>