Reference documentation and code samples for the Google Cloud OsConfig V1 Client class GroupLabel.
Targets a group of VM instances by using their assigned
labels. 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: {"env":"test", "app":"web"}. This means that the patch job
is applied to VMs that have both the labels env=test and app=web.
Generated from protobuf message google.cloud.osconfig.v1.PatchInstanceFilter.GroupLabel
Namespace
Google \ Cloud \ OsConfig \ V1 \ PatchInstanceFilter
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Google Cloud OsConfig V1 Client - Class GroupLabel (2.1.0)\n\nVersion latestkeyboard_arrow_down\n\n- [2.1.0 (latest)](/php/docs/reference/cloud-osconfig/latest/V1.PatchInstanceFilter.GroupLabel)\n- [2.0.5](/php/docs/reference/cloud-osconfig/2.0.5/V1.PatchInstanceFilter.GroupLabel)\n- [1.3.5](/php/docs/reference/cloud-osconfig/1.3.5/V1.PatchInstanceFilter.GroupLabel)\n- [1.2.2](/php/docs/reference/cloud-osconfig/1.2.2/V1.PatchInstanceFilter.GroupLabel)\n- [1.1.1](/php/docs/reference/cloud-osconfig/1.1.1/V1.PatchInstanceFilter.GroupLabel)\n- [1.0.5](/php/docs/reference/cloud-osconfig/1.0.5/V1.PatchInstanceFilter.GroupLabel) \nReference documentation and code samples for the Google Cloud OsConfig V1 Client class GroupLabel.\n\nTargets a group of VM instances by using their [assigned\nlabels](https://cloud.google.com/compute/docs/labeling-resources). Labels\nare key-value pairs. A `GroupLabel` is a combination of labels\nthat is used to target VMs for a patch job.\n\nFor example, a patch job can target VMs that have the following\n`GroupLabel`: `{\"env\":\"test\", \"app\":\"web\"}`. This means that the patch job\nis applied to VMs that have both the labels `env=test` and `app=web`.\n\nGenerated from protobuf message `google.cloud.osconfig.v1.PatchInstanceFilter.GroupLabel`\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ OsConfig \\\\ V1 \\\\ PatchInstanceFilter\n\nMethods\n-------\n\n### __construct\n\nConstructor.\n\n### getLabels\n\nCompute Engine instance labels that must be present for a VM\ninstance to be targeted by this filter.\n\n### setLabels\n\nCompute Engine instance labels that must be present for a VM\ninstance to be targeted by this filter."]]