Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve readability #3

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# CodePipeline-Nested-CFN

This repo contains the CloudFormtaion template which will create a CodePipeline containing multiple stages starting from CodeCommit as source stage, followed by build using CodeBuild, launch test stack, test using CodeBuild, proceed with UAT deployment and wait for manual approval. Once approved it proceed to production stage where it creates a CloudFormation ChangeSet for production stack and wait for approval, once approved it will execute the ChangeSet in production stack.
This repo contains the CloudFormation template which will create a CodePipeline containing multiple stages starting from CodeCommit as source stage, followed by build using CodeBuild, launch test stack, test using CodeBuild, proceed with UAT deployment and wait for manual approval. Once approved, it proceeds to production stage where it creates a CloudFormation ChangeSet for production stack and wait for approval. Once approved, it will execute the ChangeSet in production stack.

![CodePipeline Design](images/Pipeline_Design.png)

Expand Down Expand Up @@ -43,21 +43,21 @@ aws codecommit create-repository --repository-name cfn-nested-repo --repository-
aws codecommit create-repository --repository-name validate-resources --repository-description "Repository for unit testing CloudFormation resources"
```

Once the repositories are create, clone those repositories and upload the content of directories `cfn-nested-repo` & `validate-resources` in their corresponding repositories.
Once the repositories have been created, clone those repositories and upload the content of directories `cfn-nested-repo` & `validate-resources` to their corresponding repositories.

## Step 4:

### Creating CodePipeline using CloudFormation

Update the **[codepipeline-cfn-codebuild.json](codepipeline-cfn-codebuild.json)** file with the appropriate values for *ArtifactStoreS3Location, UATTopic & ProdTopic* based on the values from output section of main stack created in Step 1 and update the values for *CFNTemplateRepoName & ValidateResourcesRepoName* with appropriate values based on the repositories created in Step 3.
Update the **[codepipeline-cfn-codebuild.json](codepipeline-cfn-codebuild.json)** file with the appropriate values for *ArtifactStoreS3Location, UATTopic & ProdTopic* based on the values from the output section of the main stack created in Step 1 and update the values for *CFNTemplateRepoName & ValidateResourcesRepoName* with appropriate values based on the repositories created in Step 3.

Once the configuration file has been updated, execute the following command to create the CloudFormation stack which will create the required CodePipeline.
Once the configuration file has been updated, execute the following command to create the CloudFormation stack, which will create the required CodePipeline.

```bash
aws cloudformation create-stack --stack-name NestedCFN-CodePipeline --template-body file://codepipeline-cfn-codebuild.yml --parameters file://codepipeline-cfn-codebuild.json --capabilities CAPABILITY_NAMED_IAM
```

Once the CloudFormation successfully creates the stack, it would have created a CodePipeline with similar stages as shown below.
if CloudFormation successfully creates the stack, it will have created a CodePipeline with stages as shown below.

![CodePipeline Stages](images/Pipeline_Flow.png)

Expand Down