CfnRepositoryProps Struct
Properties for defining a CfnRepository.
| Source |
|---|
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_codeartifact as codeartifact } from 'aws-cdk-lib';
declare const permissionsPolicyDocument: any;
const cfnRepositoryProps: codeartifact.CfnRepositoryProps = {
domainName: 'domainName',
repositoryName: 'repositoryName',
// the properties below are optional
description: 'description',
domainOwner: 'domainOwner',
externalConnections: ['externalConnections'],
permissionsPolicyDocument: permissionsPolicyDocument,
tags: [{
key: 'key',
value: 'value',
}],
upstreams: ['upstreams'],
};
python
from aws_cdk import CfnTag
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_codeartifact as codeartifact
# permissions_policy_document: Any
cfn_repository_props = codeartifact.CfnRepositoryProps(
domain_name="domainName",
repository_name="repositoryName",
# the properties below are optional
description="description",
domain_owner="domainOwner",
external_connections=["externalConnections"],
permissions_policy_document=permissions_policy_document,
tags=[CfnTag(
key="key",
value="value"
)],
upstreams=["upstreams"]
)
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.codeartifact.*;
Object permissionsPolicyDocument;
CfnRepositoryProps cfnRepositoryProps = CfnRepositoryProps.builder()
.domainName("domainName")
.repositoryName("repositoryName")
// the properties below are optional
.description("description")
.domainOwner("domainOwner")
.externalConnections(List.of("externalConnections"))
.permissionsPolicyDocument(permissionsPolicyDocument)
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.upstreams(List.of("upstreams"))
.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.CodeArtifact;
var permissionsPolicyDocument;
var cfnRepositoryProps = new CfnRepositoryProps {
DomainName = "domainName",
RepositoryName = "repositoryName",
// the properties below are optional
Description = "description",
DomainOwner = "domainOwner",
ExternalConnections = new [] { "externalConnections" },
PermissionsPolicyDocument = permissionsPolicyDocument,
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} },
Upstreams = new [] { "upstreams" }
};
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 permissionsPolicyDocument interface{}
cfnRepositoryProps := &CfnRepositoryProps{
DomainName: jsii.String("domainName"),
RepositoryName: jsii.String("repositoryName"),
// the properties below are optional
Description: jsii.String("description"),
DomainOwner: jsii.String("domainOwner"),
ExternalConnections: []*string{
jsii.String("externalConnections"),
},
PermissionsPolicyDocument: permissionsPolicyDocument,
Tags: []CfnTag{
&CfnTag{
Key: jsii.String("key"),
Value: jsii.String("value"),
},
},
Upstreams: []*string{
jsii.String("upstreams"),
},
}
Properties
descriptionoptionalstringdescriptionoptionalstrdescriptionoptionalStringDescriptionoptionalstringDescriptionoptional*string #A text description of the repository.
The name of the domain that contains the repository.
domainOwneroptionalstringdomain_owneroptionalstrdomainOwneroptionalStringDomainOwneroptionalstringDomainOwneroptional*string #The 12-digit account number of the AWS account that owns the domain that contains the repository.
It does not include dashes or spaces.
externalConnectionsoptionalstring[]external_connectionsoptionaltyping.List[str]externalConnectionsoptionalList<String>ExternalConnectionsoptionalstring[]ExternalConnectionsoptional*[]*string #An array of external connections associated with the repository.
For more information, see Supported external connection repositories in the CodeArtifact user guide .
permissionsPolicyDocumentoptionalanypermissions_policy_documentoptionalAnypermissionsPolicyDocumentoptionalObjectPermissionsPolicyDocumentoptionalobjectPermissionsPolicyDocumentoptionalinterface{} #The document that defines the resource policy that is set on a repository.
repositoryNamestringrepository_namestrrepositoryNameStringRepositoryNamestringRepositoryName*string required #The name of an upstream repository.
tagsoptionalCfnTag[]tagsoptionaltyping.List[CfnTag]tagsoptionalList<CfnTag>TagsoptionalCfnTag[]Tagsoptional*[]CfnTag #A list of tags to be applied to the repository.
upstreamsoptionalstring[]upstreamsoptionaltyping.List[str]upstreamsoptionalList<String>Upstreamsoptionalstring[]Upstreamsoptional*[]*string #A list of upstream repositories to associate with the repository.
notes
The order of the upstream repositories in the list determines their priority order when AWS CodeArtifact looks for a requested package version. For more information, see Working with upstream repositories .