aws-solutions / aws-control-tower-customizations

The Customizations for AWS Control Tower solution combines AWS Control Tower and other highly-available, trusted AWS services to help customers more quickly set up a secure, multi-account AWS environment using AWS best practices.
https://docs.aws.amazon.com/controltower/latest/userguide/cfct-overview.html
Apache License 2.0
355 stars 205 forks source link

CodeCommitBranchName doesn't affect initially created branch for CodeCommit during installation #117

Closed mdaehnert closed 7 months ago

mdaehnert commented 2 years ago

Describe the bug Parameter CodeCommitBranchName can be set to change CodePipeline's CodeCommit branch to use. Unfortunately the CodeCommit repository itself will always set up its manifest etc. files on main branch.

A clear and concise description of what the bug is.

To Reproduce Install CfCT and change the CodeCommitBranchName parameter.

Expected behavior If changing the branch name for the Pipeline it should reflect installing the initial repository data into the same branch. Or at least the parameter should be renamed to tell that it only affects the CodePipeline's used branch name not the initially created on by CodeCommit.

Please complete the following information about the solution:

Additional context CloudFormation documentation for AWS::CodeCommit::Repository --> Code --> BranchName setting: https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-codecommit-repository-code.html#cfn-codecommit-repository-code-branchname

balltrev commented 2 years ago

Thanks for bringing this up, @mdaehnert. I've made a backlog for your suggestion with the team.

stumins commented 7 months ago

Hi @mdaehnert

CFCT v2.7.0 now honors this parameter during repo creation - the example code is now committed to your chosen branch instead of main.