Skip to content
v2.277.0

SourceAwsConfigurationProperty Struct ​

Configuration for AWS source account integration.

Specifies the account ID, assumable role ARN, and resources to be monitored in the source account.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_devopsagent as devopsagent } from 'aws-cdk-lib';

declare const resourceMetadata: any;
const sourceAwsConfigurationProperty: devopsagent.CfnAssociation.SourceAwsConfigurationProperty = {
  accountId: 'accountId',
  accountType: 'accountType',
  assumableRoleArn: 'assumableRoleArn',

  // the properties below are optional
  agentElevatedRoleArn: 'agentElevatedRoleArn',
  resources: [{
    resourceArn: 'resourceArn',

    // the properties below are optional
    resourceMetadata: resourceMetadata,
    resourceType: 'resourceType',
  }],
  tags: [{
    key: 'key',
    value: 'value',
  }],
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_devopsagent as devopsagent

# resource_metadata: Any

source_aws_configuration_property = devopsagent.CfnAssociation.SourceAwsConfigurationProperty(
    account_id="accountId",
    account_type="accountType",
    assumable_role_arn="assumableRoleArn",

    # the properties below are optional
    agent_elevated_role_arn="agentElevatedRoleArn",
    resources=[devopsagent.CfnAssociation.AWSResourceProperty(
        resource_arn="resourceArn",

        # the properties below are optional
        resource_metadata=resource_metadata,
        resource_type="resourceType"
    )],
    tags=[devopsagent.CfnAssociation.KeyValuePairProperty(
        key="key",
        value="value"
    )]
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.devopsagent.*;

Object resourceMetadata;

SourceAwsConfigurationProperty sourceAwsConfigurationProperty = SourceAwsConfigurationProperty.builder()
        .accountId("accountId")
        .accountType("accountType")
        .assumableRoleArn("assumableRoleArn")

        // the properties below are optional
        .agentElevatedRoleArn("agentElevatedRoleArn")
        .resources(List.of(AWSResourceProperty.builder()
                .resourceArn("resourceArn")

                // the properties below are optional
                .resourceMetadata(resourceMetadata)
                .resourceType("resourceType")
                .build()))
        .tags(List.of(KeyValuePairProperty.builder()
                .key("key")
                .value("value")
                .build()))
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.DevOpsAgent;

var resourceMetadata;

var sourceAwsConfigurationProperty = new SourceAwsConfigurationProperty {
    AccountId = "accountId",
    AccountType = "accountType",
    AssumableRoleArn = "assumableRoleArn",

    // the properties below are optional
    AgentElevatedRoleArn = "agentElevatedRoleArn",
    Resources = new [] { new AWSResourceProperty {
        ResourceArn = "resourceArn",

        // the properties below are optional
        ResourceMetadata = resourceMetadata,
        ResourceType = "resourceType"
    } },
    Tags = new [] { new KeyValuePairProperty {
        Key = "key",
        Value = "value"
    } }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

var resourceMetadata interface{}

sourceAwsConfigurationProperty := &SourceAwsConfigurationProperty{
	AccountId: jsii.String("accountId"),
	AccountType: jsii.String("accountType"),
	AssumableRoleArn: jsii.String("assumableRoleArn"),

	// the properties below are optional
	AgentElevatedRoleArn: jsii.String("agentElevatedRoleArn"),
	Resources: []interface{}{
		&AWSResourceProperty{
			ResourceArn: jsii.String("resourceArn"),

			// the properties below are optional
			ResourceMetadata: resourceMetadata,
			ResourceType: jsii.String("resourceType"),
		},
	},
	Tags: []KeyValuePairProperty{
		&KeyValuePairProperty{
			Key: jsii.String("key"),
			Value: jsii.String("value"),
		},
	},
}

Properties ​

accountIdstringaccount_idstraccountIdStringAccountIdstringAccountId*string required #
Account ID corresponding to the provided resources.
accountTypestringaccount_typestraccountTypeStringAccountTypestringAccountType*string required #
Account Type 'source' for AWS DevOps Agent monitoring.
agentElevatedRoleArnoptionalstringagent_elevated_role_arnoptionalstragentElevatedRoleArnoptionalStringAgentElevatedRoleArnoptionalstringAgentElevatedRoleArnoptional*string #
The IAM role that AWS DevOps Agent assumes to perform elevated directed actions in this AWS account.
notes

Elevated actions also require ElevatedActionsEnabled to be set in the Preferences of the AgentSpace. When not provided, only non-elevated directed actions are available. Removing this property from the template clears the role on update. Setting this role is subject to the same iam:PassRole requirement as AssumableRoleArn.

assumableRoleArnstringassumable_role_arnstrassumableRoleArnStringAssumableRoleArnstringAssumableRoleArn*string required #
Role ARN to be assumed by AWS DevOps Agent to operate on behalf of customer.
resourcesoptionalIResolvable | IResolvable | CfnAssociation.AWSResourceProperty[]resourcesoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, AWSResourceProperty]]]resourcesoptionalIResolvableResourcesoptionalIResolvableResourcesoptionalinterface{} #
List of resources to monitor.
tagsoptionalCfnAssociation.KeyValuePairProperty[]tagsoptionaltyping.List[KeyValuePairProperty]tagsoptionalList<KeyValuePairProperty>TagsoptionalKeyValuePairProperty[]Tagsoptional*[]KeyValuePairProperty #
List of tags as key-value pairs, used to identify resources for topology crawl.