Backup AWS CodeCommit repositories to Amazon S3.
(or risk discovering that deleting an AWS CodeCommit repository is a one-way operation)
module "codecommit-s3-backups" {
source = "aws-samples/codecommit-s3-backups/aws"
version = "2.2.x"
name = "codecommit-s3-backup"
}
The name
is used in the resource names (AWS CodeBuild project, IAM Roles, etc).
module "codecommit_s3_backup" {
...
kms_key = aws_kms_key.this.arn
access_logging_bucket = aws_s3_bucket.this.id
}
kms_key
is the arn of an existing AWS KMS key. It encrypts the Amazon S3 bucket and Amazon CloudWatch Log group. The AWS KMS key policy will need to follow CloudWatch Logs guidance for AWS KMS and CodeBuild guidance for AWS KMS.
access_logging_bucket
is the arn of an Amazon S3 access logging bucket.
- Automate event-driven backups from CodeCommit to Amazon S3 using CodeBuild and CloudWatch Events
- Terraform Registry: aws-samples/codecommit-s3-backups/aws
See CONTRIBUTING for more information.
This library is licensed under the MIT-0 License. See the LICENSE file.