Organization Policy V2 API - Class Google::Cloud::OrgPolicy::V2::Policy (v1.1.0)

Reference documentation and code samples for the Organization Policy V2 API class Google::Cloud::OrgPolicy::V2::Policy.

Defines an organization policy which is used to specify constraints for configurations of Google Cloud resources.

Inherits

  • Object

Extended By

  • Google::Protobuf::MessageExts::ClassMethods

Includes

  • Google::Protobuf::MessageExts

Methods

#alternate

def alternate() -> ::Google::Cloud::OrgPolicy::V2::AlternatePolicySpec

#alternate=

def alternate=(value) -> ::Google::Cloud::OrgPolicy::V2::AlternatePolicySpec
Parameter

#dry_run_spec

def dry_run_spec() -> ::Google::Cloud::OrgPolicy::V2::PolicySpec
Returns

#dry_run_spec=

def dry_run_spec=(value) -> ::Google::Cloud::OrgPolicy::V2::PolicySpec
Parameter
Returns

#etag

def etag() -> ::String
Returns
  • (::String) — Optional. An opaque tag indicating the current state of the policy, used for concurrency control. This 'etag' is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

#etag=

def etag=(value) -> ::String
Parameter
  • value (::String) — Optional. An opaque tag indicating the current state of the policy, used for concurrency control. This 'etag' is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.
Returns
  • (::String) — Optional. An opaque tag indicating the current state of the policy, used for concurrency control. This 'etag' is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.

#name

def name() -> ::String
Returns
  • (::String) — Immutable. The resource name of the policy. Must be one of the following forms, where constraint_name is the name of the constraint which this policy configures:

    • projects/{project_number}/policies/{constraint_name}
    • folders/{folder_id}/policies/{constraint_name}
    • organizations/{organization_id}/policies/{constraint_name}

    For example, projects/123/policies/compute.disableSerialPortAccess.

    Note: projects/{project_id}/policies/{constraint_name} is also an acceptable name for API requests, but responses will return the name using the equivalent project number.

#name=

def name=(value) -> ::String
Parameter
  • value (::String) — Immutable. The resource name of the policy. Must be one of the following forms, where constraint_name is the name of the constraint which this policy configures:

    • projects/{project_number}/policies/{constraint_name}
    • folders/{folder_id}/policies/{constraint_name}
    • organizations/{organization_id}/policies/{constraint_name}

    For example, projects/123/policies/compute.disableSerialPortAccess.

    Note: projects/{project_id}/policies/{constraint_name} is also an acceptable name for API requests, but responses will return the name using the equivalent project number.

Returns
  • (::String) — Immutable. The resource name of the policy. Must be one of the following forms, where constraint_name is the name of the constraint which this policy configures:

    • projects/{project_number}/policies/{constraint_name}
    • folders/{folder_id}/policies/{constraint_name}
    • organizations/{organization_id}/policies/{constraint_name}

    For example, projects/123/policies/compute.disableSerialPortAccess.

    Note: projects/{project_id}/policies/{constraint_name} is also an acceptable name for API requests, but responses will return the name using the equivalent project number.

#spec

def spec() -> ::Google::Cloud::OrgPolicy::V2::PolicySpec
Returns

#spec=

def spec=(value) -> ::Google::Cloud::OrgPolicy::V2::PolicySpec
Parameter
Returns