Hello everyone,
The first step in building my first complex cloud project is creating a CI/CD pipeline. From my code repository on GitHub to an S3 bucket on AWS.
I would like the code from the main branch of my GitHub repository to be automatically copied to my S3 bucket.
And I keep in mind that I want to use IaC as much as possible.
Why IaC (Infrastructure as Code) ?
Because I need to :
- Track all of the resources associated with my project
- Monitor the infrastructure changes
And I do not want to click around AWS Console :D
Here is a more detailed view of what I implemented :
You can find on my GitHub my CloudFormation template.
The pipeline has 3 stages :
1. Source
CodeStar Connection to my GitHub repository.
2. Build
With AWS CodeBuild. You need to put a buildspec.yaml file in your repository. You can find an example here.
3. Deploy
Unzip the files in S3 bucket.
What I found challenging :
The first times I tried to create the CloudFormation stack I had invalid format errors.
And I had a hard time finding out why.
Is there any tool to parse your CloudFormation file and identify any misconfiguration ?ROLES ! I find it really difficult to handle roles and access management.
Thank you for reading.
I am open to discussions, advices and questions.
Top comments (0)