Google Native

v0.26.0 published on Friday, Sep 16, 2022 by Pulumi

getCustomConstraint

Gets a CustomConstraint. Returns a google.rpc.Status with google.rpc.Code.NOT_FOUND if the CustomConstraint does not exist.

Using getCustomConstraint

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getCustomConstraint(args: GetCustomConstraintArgs, opts?: InvokeOptions): Promise<GetCustomConstraintResult>
function getCustomConstraintOutput(args: GetCustomConstraintOutputArgs, opts?: InvokeOptions): Output<GetCustomConstraintResult>
def get_custom_constraint(custom_constraint_id: Optional[str] = None,
                          organization_id: Optional[str] = None,
                          opts: Optional[InvokeOptions] = None) -> GetCustomConstraintResult
def get_custom_constraint_output(custom_constraint_id: Optional[pulumi.Input[str]] = None,
                          organization_id: Optional[pulumi.Input[str]] = None,
                          opts: Optional[InvokeOptions] = None) -> Output[GetCustomConstraintResult]
func LookupCustomConstraint(ctx *Context, args *LookupCustomConstraintArgs, opts ...InvokeOption) (*LookupCustomConstraintResult, error)
func LookupCustomConstraintOutput(ctx *Context, args *LookupCustomConstraintOutputArgs, opts ...InvokeOption) LookupCustomConstraintResultOutput

> Note: This function is named LookupCustomConstraint in the Go SDK.

public static class GetCustomConstraint 
{
    public static Task<GetCustomConstraintResult> InvokeAsync(GetCustomConstraintArgs args, InvokeOptions? opts = null)
    public static Output<GetCustomConstraintResult> Invoke(GetCustomConstraintInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetCustomConstraintResult> getCustomConstraint(GetCustomConstraintArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
Fn::Invoke:
  Function: google-native:orgpolicy/v2:getCustomConstraint
  Arguments:
    # Arguments dictionary

The following arguments are supported:

getCustomConstraint Result

The following output properties are available:

ActionType string

Allow or deny type.

Condition string

Org policy condition/expression. For example: resource.instanceName.matches("[production|test]_.*_(\d)+")' or, resource.management.auto_upgrade == true

Description string

Detailed information about this custom policy constraint.

DisplayName string

One line display name for the UI.

MethodTypes List<string>

All the operations being applied for this constraint.

Name string

Immutable. Name of the constraint. This is unique within the organization. Format of the name should be * organizations/{organization_id}/customConstraints/{custom_constraint_id} Example : "organizations/123/customConstraints/custom.createOnlyE2TypeVms"

ResourceTypes List<string>

Immutable. The Resource Instance type on which this policy applies to. Format will be of the form : "/" Example: * compute.googleapis.com/Instance.

UpdateTime string

The last time this custom constraint was updated. This represents the last time that the CreateCustomConstraint or UpdateCustomConstraint RPC was called

ActionType string

Allow or deny type.

Condition string

Org policy condition/expression. For example: resource.instanceName.matches("[production|test]_.*_(\d)+")' or, resource.management.auto_upgrade == true

Description string

Detailed information about this custom policy constraint.

DisplayName string

One line display name for the UI.

MethodTypes []string

All the operations being applied for this constraint.

Name string

Immutable. Name of the constraint. This is unique within the organization. Format of the name should be * organizations/{organization_id}/customConstraints/{custom_constraint_id} Example : "organizations/123/customConstraints/custom.createOnlyE2TypeVms"

ResourceTypes []string

Immutable. The Resource Instance type on which this policy applies to. Format will be of the form : "/" Example: * compute.googleapis.com/Instance.

UpdateTime string

The last time this custom constraint was updated. This represents the last time that the CreateCustomConstraint or UpdateCustomConstraint RPC was called

actionType String

Allow or deny type.

condition String

Org policy condition/expression. For example: resource.instanceName.matches("[production|test]_.*_(\d)+")' or, resource.management.auto_upgrade == true

description String

Detailed information about this custom policy constraint.

displayName String

One line display name for the UI.

methodTypes List<String>

All the operations being applied for this constraint.

name String

Immutable. Name of the constraint. This is unique within the organization. Format of the name should be * organizations/{organization_id}/customConstraints/{custom_constraint_id} Example : "organizations/123/customConstraints/custom.createOnlyE2TypeVms"

resourceTypes List<String>

Immutable. The Resource Instance type on which this policy applies to. Format will be of the form : "/" Example: * compute.googleapis.com/Instance.

updateTime String

The last time this custom constraint was updated. This represents the last time that the CreateCustomConstraint or UpdateCustomConstraint RPC was called

actionType string

Allow or deny type.

condition string

Org policy condition/expression. For example: resource.instanceName.matches("[production|test]_.*_(\d)+")' or, resource.management.auto_upgrade == true

description string

Detailed information about this custom policy constraint.

displayName string

One line display name for the UI.

methodTypes string[]

All the operations being applied for this constraint.

name string

Immutable. Name of the constraint. This is unique within the organization. Format of the name should be * organizations/{organization_id}/customConstraints/{custom_constraint_id} Example : "organizations/123/customConstraints/custom.createOnlyE2TypeVms"

resourceTypes string[]

Immutable. The Resource Instance type on which this policy applies to. Format will be of the form : "/" Example: * compute.googleapis.com/Instance.

updateTime string

The last time this custom constraint was updated. This represents the last time that the CreateCustomConstraint or UpdateCustomConstraint RPC was called

action_type str

Allow or deny type.

condition str

Org policy condition/expression. For example: resource.instanceName.matches("[production|test]_.*_(\d)+")' or, resource.management.auto_upgrade == true

description str

Detailed information about this custom policy constraint.

display_name str

One line display name for the UI.

method_types Sequence[str]

All the operations being applied for this constraint.

name str

Immutable. Name of the constraint. This is unique within the organization. Format of the name should be * organizations/{organization_id}/customConstraints/{custom_constraint_id} Example : "organizations/123/customConstraints/custom.createOnlyE2TypeVms"

resource_types Sequence[str]

Immutable. The Resource Instance type on which this policy applies to. Format will be of the form : "/" Example: * compute.googleapis.com/Instance.

update_time str

The last time this custom constraint was updated. This represents the last time that the CreateCustomConstraint or UpdateCustomConstraint RPC was called

actionType String

Allow or deny type.

condition String

Org policy condition/expression. For example: resource.instanceName.matches("[production|test]_.*_(\d)+")' or, resource.management.auto_upgrade == true

description String

Detailed information about this custom policy constraint.

displayName String

One line display name for the UI.

methodTypes List<String>

All the operations being applied for this constraint.

name String

Immutable. Name of the constraint. This is unique within the organization. Format of the name should be * organizations/{organization_id}/customConstraints/{custom_constraint_id} Example : "organizations/123/customConstraints/custom.createOnlyE2TypeVms"

resourceTypes List<String>

Immutable. The Resource Instance type on which this policy applies to. Format will be of the form : "/" Example: * compute.googleapis.com/Instance.

updateTime String

The last time this custom constraint was updated. This represents the last time that the CreateCustomConstraint or UpdateCustomConstraint RPC was called

Package Details

Repository
https://github.com/pulumi/pulumi-google-native
License
Apache-2.0