Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
carlssonk authored Sep 27, 2024
1 parent 5d7dbd6 commit dc31baf
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@
![CI Pipeline Diagram](ci-pipeline-diagram.png)

## Guide
> Note: Use `chmod +x ./scripts/symlink_modules.sh` and `./scripts/symlink_modules.sh` to create a symlinked default/ folder
> Note: Use `chmod +x ./scripts/symlink_modules.sh` and `./scripts/symlink_modules.sh` to create a symlinked default/ folder. Needs to be done if installing repo for the first time or when adding new modules
### Set up and create infra on a new environment
1. Create a new AWS account
2. Create a new IAM bootstrap user and add [this](bootstrap/README.md) as inline policy
3. Enable `Allow GitHub Actions to create and approve pull requests` in Github Actions -> General (if you're using the `ad-m/github-push-action@master` step)
4. Set up a new repository environment in Github
5. Add `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` secrets in the repository environment
6. Create a new branch and make sure the name of the branch is the same as the name of the repository environment
7. Push changes to new branch
6. Push changes to main
7. Trigger workflow_dispatch on "Deploy Infrastructure". If environment does not exist in dropdown you need to add it [here](https://github.com/carlssonk/terraform-aws-infra/blob/main/.github/workflows/deploy.yml#L10)
8. Done

### Destroy infra for an environment
Expand Down Expand Up @@ -84,4 +84,4 @@ Cloudflare -> Load Balancer (public subnets) -> Services (no need for public/pri

Debug ec2 instance:
cat /var/log/cloud-init-output.log
cat /var/log/cloud-init.log
cat /var/log/cloud-init.log

0 comments on commit dc31baf

Please sign in to comment.