Class OsConfigOsPolicyAssignmentOsPolicies.Builder
- java.lang.Object
-
- com.hashicorp.cdktf.providers.google.os_config_os_policy_assignment.OsConfigOsPolicyAssignmentOsPolicies.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<OsConfigOsPolicyAssignmentOsPolicies>
- Enclosing interface:
- OsConfigOsPolicyAssignmentOsPolicies
@Stability(Stable) public static final class OsConfigOsPolicyAssignmentOsPolicies.Builder extends Object implements software.amazon.jsii.Builder<OsConfigOsPolicyAssignmentOsPolicies>
A builder forOsConfigOsPolicyAssignmentOsPolicies
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
-
-
-
Method Detail
-
id
@Stability(Stable) public OsConfigOsPolicyAssignmentOsPolicies.Builder id(String id)
Sets the value ofOsConfigOsPolicyAssignmentOsPolicies.getId()- Parameters:
id- The id of the OS policy with the following restrictions: * Must contain only lowercase letters, numbers, and hyphens. This parameter is required. * Must start with a letter. * Must be between 1-63 characters. * Must end with a number or a letter. * Must be unique within the assignment. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/os_config_os_policy_assignment#id OsConfigOsPolicyAssignment#id} Please be aware that the id field is automatically added to all resources in Terraform providers using a Terraform provider SDK version below 2. If you experience problems setting this value it might not be settable. Please take a look at the provider documentation to ensure it should be settable.- Returns:
this
-
mode
@Stability(Stable) public OsConfigOsPolicyAssignmentOsPolicies.Builder mode(String mode)
Sets the value ofOsConfigOsPolicyAssignmentOsPolicies.getMode()- Parameters:
mode- Policy mode Possible values: ["MODE_UNSPECIFIED", "VALIDATION", "ENFORCEMENT"]. This parameter is required. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/os_config_os_policy_assignment#mode OsConfigOsPolicyAssignment#mode}- Returns:
this
-
resourceGroups
@Stability(Stable) public OsConfigOsPolicyAssignmentOsPolicies.Builder resourceGroups(com.hashicorp.cdktf.IResolvable resourceGroups)
Sets the value ofOsConfigOsPolicyAssignmentOsPolicies.getResourceGroups()- Parameters:
resourceGroups- resource_groups block. This parameter is required. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/os_config_os_policy_assignment#resource_groups OsConfigOsPolicyAssignment#resource_groups}- Returns:
this
-
resourceGroups
@Stability(Stable) public OsConfigOsPolicyAssignmentOsPolicies.Builder resourceGroups(List<? extends OsConfigOsPolicyAssignmentOsPoliciesResourceGroups> resourceGroups)
Sets the value ofOsConfigOsPolicyAssignmentOsPolicies.getResourceGroups()- Parameters:
resourceGroups- resource_groups block. This parameter is required. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/os_config_os_policy_assignment#resource_groups OsConfigOsPolicyAssignment#resource_groups}- Returns:
this
-
allowNoResourceGroupMatch
@Stability(Stable) public OsConfigOsPolicyAssignmentOsPolicies.Builder allowNoResourceGroupMatch(Boolean allowNoResourceGroupMatch)
Sets the value ofOsConfigOsPolicyAssignmentOsPolicies.getAllowNoResourceGroupMatch()- Parameters:
allowNoResourceGroupMatch- This flag determines the OS policy compliance status when none of the resource groups within the policy are applicable for a VM. Set this value to 'true' if the policy needs to be reported as compliant even if the policy has nothing to validate or enforce. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/os_config_os_policy_assignment#allow_no_resource_group_match OsConfigOsPolicyAssignment#allow_no_resource_group_match}- Returns:
this
-
allowNoResourceGroupMatch
@Stability(Stable) public OsConfigOsPolicyAssignmentOsPolicies.Builder allowNoResourceGroupMatch(com.hashicorp.cdktf.IResolvable allowNoResourceGroupMatch)
Sets the value ofOsConfigOsPolicyAssignmentOsPolicies.getAllowNoResourceGroupMatch()- Parameters:
allowNoResourceGroupMatch- This flag determines the OS policy compliance status when none of the resource groups within the policy are applicable for a VM. Set this value to 'true' if the policy needs to be reported as compliant even if the policy has nothing to validate or enforce. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/os_config_os_policy_assignment#allow_no_resource_group_match OsConfigOsPolicyAssignment#allow_no_resource_group_match}- Returns:
this
-
description
@Stability(Stable) public OsConfigOsPolicyAssignmentOsPolicies.Builder description(String description)
Sets the value ofOsConfigOsPolicyAssignmentOsPolicies.getDescription()- Parameters:
description- Policy description. Length of the description is limited to 1024 characters. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/os_config_os_policy_assignment#description OsConfigOsPolicyAssignment#description}- Returns:
this
-
build
@Stability(Stable) public OsConfigOsPolicyAssignmentOsPolicies build()
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<OsConfigOsPolicyAssignmentOsPolicies>- Returns:
- a new instance of
OsConfigOsPolicyAssignmentOsPolicies - Throws:
NullPointerException- if any required attribute was not provided
-
-