I am working with setting up a AWS CodeBuild project in Terraform. Looking at the Terraform docs https://www.terraform.io/docs/providers/aws/r/codebuild_project.html I cannot figure out which argument to use to define the source version as highlighted in the image:
Is this option supported though Terraform? I would like the CodeBuild project to build from another branch's source code than master.
You can use source_version as it mentioned in the doc you referenced https://www.terraform.io/docs/providers/aws/r/codebuild_project.html
source_version = "master"
Specifying branch in source_version works the same way as in AWS console, e.g.
source_version = "refs/heads/my-feature-branch"
Other examples with tag, pull requests can be found here: https://docs.aws.amazon.com/codebuild/latest/userguide/sample-source-version.html
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With