Package-level declarations
Types
Message encapsulating a value that can be either absolute ("fixed") or relative ("percent") to a value.
Builder for FixedOrPercentArgs.
Builder for GetOsPolicyAssignmentPlainArgs.
An OS policy defines the desired state configuration for a VM.
Builder for OSPolicyArgs.
Filters to select target VMs for an assignment. If more than one filter criteria is specified below, a VM will be selected if and only if it satisfies all of them.
VM inventory details.
Message representing label set. * A label is a key value pair set for a VM. * A LabelSet is a set of labels. * Labels within a LabelSet are ANDed. In other words, a LabelSet is applicable for a VM only if it matches all the labels in the LabelSet. * Example: A LabelSet with 2 labels: env=prod
and type=webserver
will only be applicable for those VMs with both labels present.
Builder for OSPolicyAssignmentLabelSetArgs.
Message to configure the rollout at the zonal level for the OS policy assignment.
Builder for OSPolicyAssignmentRolloutArgs.
Filtering criteria to select VMs based on inventory details.
Builder for OSPolicyInventoryFilterArgs.
Filtering criteria to select VMs based on OS details.
Builder for OSPolicyOSFilterArgs.
An OS policy resource is used to define the desired state configuration and provides a specific functionality like installing/removing packages, executing a script etc. The system ensures that resources are always in their desired state by taking necessary actions if they have drifted from their desired state.
Builder for OSPolicyResourceArgs.
A resource that allows executing scripts on the VM. The ExecResource
has 2 stages: validate
and enforce
and both stages accept a script as an argument to execute. When the ExecResource
is applied by the agent, it first executes the script in the validate
stage. The validate
stage can signal that the ExecResource
is already in the desired state by returning an exit code of 100
. If the ExecResource
is not in the desired state, it should return an exit code of 101
. Any other exit code returned by this stage is considered an error. If the ExecResource
is not in the desired state based on the exit code from the validate
stage, the agent proceeds to execute the script from the enforce
stage. If the ExecResource
is already in the desired state, the enforce
stage will not be run. Similar to validate
stage, the enforce
stage should return an exit code of 100
to indicate that the resource in now in its desired state. Any other exit code is considered an error. NOTE: An exit code of 100
was chosen over 0
(and 101
vs 1
) to have an explicit indicator of in desired state
, not in desired state
and errors. Because, for example, Powershell will always return an exit code of 0
unless an exit
statement is provided in the script. So, for reasons of consistency and being explicit, exit codes 100
and 101
were chosen.
Builder for OSPolicyResourceExecResourceArgs.
A file or script to execute.
A remote or local file.
Builder for OSPolicyResourceFileArgs.
Specifies a file available as a Cloud Storage Object.
Builder for OSPolicyResourceFileGcsArgs.
Specifies a file available via some URI.
Builder for OSPolicyResourceFileRemoteArgs.
A resource that manages the state of a file.
Builder for OSPolicyResourceFileResourceArgs.
Resource groups provide a mechanism to group OS policy resources. Resource groups enable OS policy authors to create a single OS policy to be applied to VMs running different operating Systems. When the OS policy is applied to a target VM, the appropriate resource group within the OS policy is selected based on the OSFilter
specified within the resource group.
Builder for OSPolicyResourceGroupArgs.
A package managed by APT. - install: apt-get update && apt-get -y install [name]
- remove: apt-get -y remove [name]
A resource that manages a system package.
A deb package file. dpkg packages only support INSTALLED state.
A package managed by GooGet. - install: googet -noconfirm install package
- remove: googet -noconfirm remove package
An MSI package. MSI packages only support INSTALLED state.
An RPM package file. RPM packages only support INSTALLED state.
A package managed by YUM. - install: yum -y install package
- remove: yum -y remove package
A package managed by Zypper. - install: zypper -y install package
- remove: zypper -y rm package
Represents a single apt package repository. These will be added to a repo file that will be managed at /etc/apt/sources.list.d/google_osconfig.list
.
A resource that manages a package repository.
Represents a Goo package repository. These are added to a repo file that is managed at C:/ProgramData/GooGet/repos/google_osconfig.repo
.
Represents a single yum package repository. These are added to a repo file that is managed at /etc/yum.repos.d/google_osconfig.repo
.
Represents a single zypper package repository. These are added to a repo file that is managed at /etc/zypp/repos.d/google_osconfig.repo
.