Reputation: 88367
I have setup my CodePipeline something like:
Maybe I am creating my pipeline wrong?
Upvotes: 0
Views: 244
Reputation: 326
Maybe in the step 3. You setup your cloudformation in this way:
1- create the database...Export as an output the name of the database
Outputs:
DataBaseName:
Description: "Name of the Database"
Value: !Ref DataBaseName
2- In the codebuild use the Boto3 and use the Describe Stacks and get the output (the name of the database and another information about it), now you could take advangate of Python in your codebuild and start the migration usign Boto3.
response = client.describe_stacks(
StackName='string',
NextToken='string'
)
Upvotes: 0
Reputation: 1597
The CloudFormation action can output stack parameters, but currently the CodeBuild action in CodePipeline can't accept both a code artifact and an artifact with CloudFormation outputs.
For now I'd call aws cloudformation describe-stacks from the CLI inside your build script to retrieve the DB information from your CloudFormation stacks.
Upvotes: 1