AuthorizedOrgsDesc class
An authorized organizations description describes a list of organizations (1) that have been authorized to use certain asset (for example, device) data owned by different organizations at the enforcement points, or (2) with certain asset (for example, device) have been authorized to access the resources in another organization at the enforcement points.
To get more information about AuthorizedOrgsDesc, see:
- API documentation
- How-to Guides
- gcloud docs
> Warning: If you are using User ADCs (Application Default Credentials) with this resource,
you must specify a billingProject and set userProjectOverride to true
in the provider configuration. Otherwise the ACM API will return a 403 error.
Your account must have the serviceusage.services.use permission on the
billingProject you defined.
Example Usage
Access Context Manager Authorized Orgs Desc Basic
import * as pulumi from "@pulumi/pulumi";
import * as gcp from "@pulumi/gcp";
const test_access = new gcp.accesscontextmanager.AccessPolicy("test-access", {
parent: "organizations/123456789",
title: "my policy",
});
const authorized_orgs_desc = new gcp.accesscontextmanager.AuthorizedOrgsDesc("authorized-orgs-desc", {
parent: pulumi.interpolate`accessPolicies/${test_access.name}`,
name: pulumi.interpolate`accessPolicies/${test_access.name}/authorizedOrgsDescs/fakeDescName`,
authorizationType: "AUTHORIZATION_TYPE_TRUST",
assetType: "ASSET_TYPE_CREDENTIAL_STRENGTH",
authorizationDirection: "AUTHORIZATION_DIRECTION_TO",
orgs: [
"organizations/12345",
"organizations/98765",
],
});
import pulumi
import pulumi_gcp as gcp
test_access = gcp.accesscontextmanager.AccessPolicy("test-access",
parent="organizations/123456789",
title="my policy")
authorized_orgs_desc = gcp.accesscontextmanager.AuthorizedOrgsDesc("authorized-orgs-desc",
parent=test_access.name.apply(lambda name: f"accessPolicies/{name}"),
name=test_access.name.apply(lambda name: f"accessPolicies/{name}/authorizedOrgsDescs/fakeDescName"),
authorization_type="AUTHORIZATION_TYPE_TRUST",
asset_type="ASSET_TYPE_CREDENTIAL_STRENGTH",
authorization_direction="AUTHORIZATION_DIRECTION_TO",
orgs=[
"organizations/12345",
"organizations/98765",
])
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Gcp = Pulumi.Gcp;
return await Deployment.RunAsync(() =>
{
var test_access = new Gcp.AccessContextManager.AccessPolicy("test-access", new()
{
Parent = "organizations/123456789",
Title = "my policy",
});
var authorized_orgs_desc = new Gcp.AccessContextManager.AuthorizedOrgsDesc("authorized-orgs-desc", new()
{
Parent = test_access.Name.Apply(name => $"accessPolicies/{name}"),
Name = test_access.Name.Apply(name => $"accessPolicies/{name}/authorizedOrgsDescs/fakeDescName"),
AuthorizationType = "AUTHORIZATION_TYPE_TRUST",
AssetType = "ASSET_TYPE_CREDENTIAL_STRENGTH",
AuthorizationDirection = "AUTHORIZATION_DIRECTION_TO",
Orgs = new[]
{
"organizations/12345",
"organizations/98765",
},
});
});
package main
import (
"fmt"
"github.com/pulumi/pulumi-gcp/sdk/v9/go/gcp/accesscontextmanager"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
test_access, err := accesscontextmanager.NewAccessPolicy(ctx, "test-access", &accesscontextmanager.AccessPolicyArgs{
Parent: pulumi.String("organizations/123456789"),
Title: pulumi.String("my policy"),
})
if err != nil {
return err
}
_, err = accesscontextmanager.NewAuthorizedOrgsDesc(ctx, "authorized-orgs-desc", &accesscontextmanager.AuthorizedOrgsDescArgs{
Parent: test_access.Name.ApplyT(func(name string) (string, error) {
return fmt.Sprintf("accessPolicies/%v", name), nil
}).(pulumi.StringOutput),
Name: test_access.Name.ApplyT(func(name string) (string, error) {
return fmt.Sprintf("accessPolicies/%v/authorizedOrgsDescs/fakeDescName", name), nil
}).(pulumi.StringOutput),
AuthorizationType: pulumi.String("AUTHORIZATION_TYPE_TRUST"),
AssetType: pulumi.String("ASSET_TYPE_CREDENTIAL_STRENGTH"),
AuthorizationDirection: pulumi.String("AUTHORIZATION_DIRECTION_TO"),
Orgs: pulumi.StringArray{
pulumi.String("organizations/12345"),
pulumi.String("organizations/98765"),
},
})
if err != nil {
return err
}
return nil
})
}
pulumi {
required_providers {
gcp = {
source = "pulumi/gcp"
}
}
}
resource "gcp_accesscontextmanager_authorizedorgsdesc" "authorized-orgs-desc" {
parent ="accessPolicies/${gcp_accesscontextmanager_accesspolicy.test-access.name}"
name ="accessPolicies/${gcp_accesscontextmanager_accesspolicy.test-access.name}/authorizedOrgsDescs/fakeDescName"
authorization_type = "AUTHORIZATION_TYPE_TRUST"
asset_type = "ASSET_TYPE_CREDENTIAL_STRENGTH"
authorization_direction = "AUTHORIZATION_DIRECTION_TO"
orgs = ["organizations/12345", "organizations/98765"]
}
resource "gcp_accesscontextmanager_accesspolicy" "test-access" {
parent = "organizations/123456789"
title = "my policy"
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.accesscontextmanager.AccessPolicy;
import com.pulumi.gcp.accesscontextmanager.AccessPolicyArgs;
import com.pulumi.gcp.accesscontextmanager.AuthorizedOrgsDesc;
import com.pulumi.gcp.accesscontextmanager.AuthorizedOrgsDescArgs;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var test_access = new AccessPolicy("test-access", AccessPolicyArgs.builder()
.parent("organizations/123456789")
.title("my policy")
.build());
var authorized_orgs_desc = new AuthorizedOrgsDesc("authorized-orgs-desc", AuthorizedOrgsDescArgs.builder()
.parent(test_access.name().applyValue(_name -> String.format("accessPolicies/%s", _name)))
.name(test_access.name().applyValue(_name -> String.format("accessPolicies/%s/authorizedOrgsDescs/fakeDescName", _name)))
.authorizationType("AUTHORIZATION_TYPE_TRUST")
.assetType("ASSET_TYPE_CREDENTIAL_STRENGTH")
.authorizationDirection("AUTHORIZATION_DIRECTION_TO")
.orgs(
"organizations/12345",
"organizations/98765")
.build());
}
}
resources:
authorized-orgs-desc:
type: gcp:accesscontextmanager:AuthorizedOrgsDesc
properties:
parent: accessPolicies/${["test-access"].name}
name: accessPolicies/${["test-access"].name}/authorizedOrgsDescs/fakeDescName
authorizationType: AUTHORIZATION_TYPE_TRUST
assetType: ASSET_TYPE_CREDENTIAL_STRENGTH
authorizationDirection: AUTHORIZATION_DIRECTION_TO
orgs:
- organizations/12345
- organizations/98765
test-access:
type: gcp:accesscontextmanager:AccessPolicy
properties:
parent: organizations/123456789
title: my policy
Import
AuthorizedOrgsDesc can be imported using any of these accepted formats:
{{name}}
When using the pulumi import command, AuthorizedOrgsDesc can be imported using one of the formats above. For example:
$ pulumi import gcp:accesscontextmanager/authorizedOrgsDesc:AuthorizedOrgsDesc default {{name}}
Constructors
- AuthorizedOrgsDesc(String name, {AuthorizedOrgsDescArgs? args, CustomResourceOptions? options})
-
Creates a new AuthorizedOrgsDesc.
nameThe Pulumi resource name.argsArguments used to configure this AuthorizedOrgsDesc. The set of arguments for AuthorizedOrgsDesc.optionsResource options controlling this resource's behavior. - AuthorizedOrgsDesc.reference(String urn)
- Creates a typed reference to an existing AuthorizedOrgsDesc resource.
Properties
-
assetType
↔ Output<
String?> -
The type of entities that need to use the authorization relationship during
evaluation, such as a device. Valid values are "ASSET_TYPE_DEVICE" and
"ASSET_TYPE_CREDENTIAL_STRENGTH".
Possible values are:
ASSET_TYPE_DEVICE,ASSET_TYPE_CREDENTIAL_STRENGTH.latefinal -
The direction of the authorization relationship between this organization
and the organizations listed in the "orgs" field. The valid values for this
field include the following:
AUTHORIZATION_DIRECTION_FROM: Allows this organization to evaluate traffic
in the organizations listed in the
orgsfield. AUTHORIZATION_DIRECTION_TO: Allows the organizations listed in theorgsfield to evaluate the traffic in this organization. For the authorization relationship to take effect, all of the organizations must authorize and specify the appropriate relationship direction. For example, if organization A authorized organization B and C to evaluate its traffic, by specifying "AUTHORIZATION_DIRECTION_TO" as the authorization direction, organizations B and C must specify "AUTHORIZATION_DIRECTION_FROM" as the authorization direction in their "AuthorizedOrgsDesc" resource. Possible values are:AUTHORIZATION_DIRECTION_TO,AUTHORIZATION_DIRECTION_FROM.latefinal -
A granular control type for authorization levels. Valid value is "AUTHORIZATION_TYPE_TRUST".
Possible values are:
AUTHORIZATION_TYPE_TRUST.latefinal -
childResources
→ Set<
Resource> -
finalinherited
-
completionSources
↔ Map<
String, IOutputCompletionSource> -
latefinalinherited
-
createTime
↔ Output<
String> -
Time the AuthorizedOrgsDesc was created in UTC.
latefinal
-
deletionPolicy
↔ Output<
String> -
Whether Terraform will be prevented from destroying the resource. Defaults to DELETE.
When a 'terraform destroy' or 'pulumi up' would delete the resource,
the command will fail if this field is set to "PREVENT" in Terraform state.
When set to "ABANDON", the command will remove the resource from Terraform
management without updating or deleting the resource in the API.
When set to "DELETE", deleting the resource is allowed.
latefinal
- hashCode → int
-
The hash code for this object.
no setterinherited
-
id
↔ Output<
String> -
getter/setter pairinherited
- isCustom → bool
-
Returns whether this resource is provider-managed.
no setterinherited
- isProtected → bool
-
Returns whether this resource is protected from deletion.
no setterinherited
- isRemote → bool
-
Whether this resource is registered as remote.
no setterinherited
- isResourceReference → bool
-
Whether this instance represents a resource value returned over RPC.
finalinherited
-
name
↔ Output<
String> -
Resource name for the
AuthorizedOrgsDesc. Format:accessPolicies/{access_policy}/authorizedOrgsDescs/{authorized_orgs_desc}. TheauthorizedOrgsDesccomponent must begin with a letter, followed by alphanumeric characters or_. After you create anAuthorizedOrgsDesc, you cannot change itsname.latefinal -
orgs
↔ Output<
List< String> ?> -
The list of organization ids in this AuthorizedOrgsDesc.
Format:
organizations/<org_number>Example:organizations/123456latefinal -
parent
↔ Output<
String> -
Required. Resource name for the access policy which owns this
AuthorizedOrgsDesc.latefinal -
resourceTransforms
→ List<
ResourceTransform> -
Inherited/explicit async transforms.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
transformations
→ List<
ResourceTransformation> -
Inherited/explicit legacy transformations.
no setterinherited
-
updateTime
↔ Output<
String> -
Time the AuthorizedOrgsDesc was updated in UTC.
latefinal
-
urn
↔ Output<
String> -
latefinalinherited
Methods
-
failId(
Object error) → void -
Completes this resource ID with an error when registration fails.
inherited
-
failOutputs(
Object error) → void -
Completes all output properties with
error.inherited -
failUrn(
Object error) → void -
Completes this resource URN with an error when registration fails.
inherited
-
getProvider(
String moduleMember) → ProviderResource? -
Returns provider for
moduleMember's package, if configured.inherited -
getResourceName(
) → String -
Returns this resource's logical name.
inherited
-
getResourceType(
) → String -
Returns this resource's Pulumi type token.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
registerOutput<
T> (String propertyName, {Object? decoder(Object?)?, bool isSecret = false}) → Output< T> -
Registers a dynamic output property for this resource.
inherited
-
resolveId(
String? value, {required bool isKnown}) → void -
Resolves the provider-assigned ID for this resource.
inherited
-
resolveOutputs(
Struct outputs) → void -
Resolves all output properties from a monitor response payload.
inherited
-
resolveUrn(
String value) → void -
Resolves this resource's URN once assigned by the engine.
inherited
-
serializeProperties(
Map< String, dynamic> properties) → Future<Struct> -
Serializes resource properties for RPC transmission.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
get(
String name, Input< String> id, {AuthorizedOrgsDescState? state, CustomResourceOptions? options}) → AuthorizedOrgsDesc -
Gets an existing AuthorizedOrgsDesc resource's state with the given
nameandid.