RepositoryProps
- class aws_cdk.aws_codecommit.RepositoryProps(*, repository_name, code=None, description=None, kms_key=None)
Bases:
object
- Parameters:
repository_name (
str
) – Name of the repository. This property is required for all CodeCommit repositories.code (
Optional
[Code
]) – The contents with which to initialize the repository after it has been created. Default: - No initialization (create empty repo)description (
Optional
[str
]) – A description of the repository. Use the description to identify the purpose of the repository. Default: - No description.kms_key (
Optional
[IKey
]) – The customer managed key used to encrypt and decrypt the data in repository. Default: - Use an AWS managed key
- ExampleMetadata:
infused
Example:
# project: codebuild.PipelineProject repository = codecommit.Repository(self, "MyRepository", repository_name="MyRepository" ) project = codebuild.PipelineProject(self, "MyProject") source_output = codepipeline.Artifact() source_action = codepipeline_actions.CodeCommitSourceAction( action_name="CodeCommit", repository=repository, output=source_output ) build_action = codepipeline_actions.CodeBuildAction( action_name="CodeBuild", project=project, input=source_output, outputs=[codepipeline.Artifact()], # optional execute_batch_build=True, # optional, defaults to false combine_batch_build_artifacts=True ) codepipeline.Pipeline(self, "MyPipeline", stages=[codepipeline.StageProps( stage_name="Source", actions=[source_action] ), codepipeline.StageProps( stage_name="Build", actions=[build_action] ) ] )
Attributes
- code
The contents with which to initialize the repository after it has been created.
- Default:
No initialization (create empty repo)
- description
A description of the repository.
Use the description to identify the purpose of the repository.
- Default:
No description.
- kms_key
The customer managed key used to encrypt and decrypt the data in repository.
- Default:
Use an AWS managed key
- repository_name
Name of the repository.
This property is required for all CodeCommit repositories.