Show / Hide Table of Contents

Class OrganizationPolicy

Allows management of Organization policies for a Google Project. For more information see the official documentation and API.

Example Usage

using Pulumi;
using Gcp = Pulumi.Gcp;

class MyStack : Stack
{
public MyStack()
{
    var serialPortPolicy = new Gcp.Projects.OrganizationPolicy("serialPortPolicy", new Gcp.Projects.OrganizationPolicyArgs
    {
        BooleanPolicy = new Gcp.Projects.Inputs.OrganizationPolicyBooleanPolicyArgs
        {
            Enforced = true,
        },
        Constraint = "compute.disableSerialPortAccess",
        Project = "your-project-id",
    });
}

}
Inheritance
System.Object
Resource
CustomResource
OrganizationPolicy
Inherited Members
CustomResource.Id
Resource.GetResourceType()
Resource.GetResourceName()
Resource.Urn
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Pulumi.Gcp.Projects
Assembly: Pulumi.Gcp.dll
Syntax
public class OrganizationPolicy : CustomResource

Constructors

View Source

OrganizationPolicy(String, OrganizationPolicyArgs, CustomResourceOptions)

Create a OrganizationPolicy resource with the given unique name, arguments, and options.

Declaration
public OrganizationPolicy(string name, OrganizationPolicyArgs args, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resource

OrganizationPolicyArgs args

The arguments used to populate this resource's properties

CustomResourceOptions options

A bag of options that control this resource's behavior

Properties

View Source

BooleanPolicy

A boolean policy is a constraint that is either enforced or not. Structure is documented below.

Declaration
public Output<OrganizationPolicyBooleanPolicy> BooleanPolicy { get; }
Property Value
Type Description
Output<OrganizationPolicyBooleanPolicy>
View Source

Constraint

The name of the Constraint the Policy is configuring, for example, serviceuser.services. Check out the complete list of available constraints.

Declaration
public Output<string> Constraint { get; }
Property Value
Type Description
Output<System.String>
View Source

Etag

(Computed) The etag of the organization policy. etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other.

Declaration
public Output<string> Etag { get; }
Property Value
Type Description
Output<System.String>
View Source

ListPolicy

A policy that can define specific values that are allowed or denied for the given constraint. It can also be used to allow or deny all values. Structure is documented below.

Declaration
public Output<OrganizationPolicyListPolicy> ListPolicy { get; }
Property Value
Type Description
Output<OrganizationPolicyListPolicy>
View Source

Project

The project id of the project to set the policy for.

Declaration
public Output<string> Project { get; }
Property Value
Type Description
Output<System.String>
View Source

RestorePolicy

A restore policy is a constraint to restore the default policy. Structure is documented below.

Declaration
public Output<OrganizationPolicyRestorePolicy> RestorePolicy { get; }
Property Value
Type Description
Output<OrganizationPolicyRestorePolicy>
View Source

UpdateTime

(Computed) The timestamp in RFC3339 UTC "Zulu" format, accurate to nanoseconds, representing when the variable was last updated. Example: "2016-10-09T12:33:37.578138407Z".

Declaration
public Output<string> UpdateTime { get; }
Property Value
Type Description
Output<System.String>
View Source

Version

Version of the Policy. Default version is 0.

Declaration
public Output<int> Version { get; }
Property Value
Type Description
Output<System.Int32>

Methods

View Source

Get(String, Input<String>, OrganizationPolicyState, CustomResourceOptions)

Get an existing OrganizationPolicy resource's state with the given name, ID, and optional extra properties used to qualify the lookup.

Declaration
public static OrganizationPolicy Get(string name, Input<string> id, OrganizationPolicyState state = null, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resulting resource.

Input<System.String> id

The unique provider ID of the resource to lookup.

OrganizationPolicyState state

Any extra arguments used during the lookup.

CustomResourceOptions options

A bag of options that control this resource's behavior

Returns
Type Description
OrganizationPolicy
  • View Source
Back to top Copyright 2016-2020, Pulumi Corporation.