> **Page index:** https://km.oslo.systems/llms.txt lists every page on this site, with a link to its Markdown version.

# Set up CI/CD common

Install the `cicd-common` stack to be able to run GitHub Actions workflows for Terraform.

## Step 1: Install `cicd-common`

repo-iac/environments/dev/

```
ok pkg add cicd-common
cd cicd-common
ok pkg install
```

To configure proper IAM roles and resources in AWS, update `config_override.tf`:

repo-iac/environments/dev/cicd-common/config\_override.tf

```
locals {
  trusted_repositories = [
    {
      name  = "<repo-name>"
      type  = "infra"
    },
  ]
}
```

Update these values:

| Field | Description | Example |
| --- | --- | --- |
| `<repo-name>` | Name of your IaC repository | `pirates-iac` |

## Step 2: Apply

Commit and push to main (or via a pull request).

Apply the new Terraform code from your local machine:

repo-iac/environments/dev/cicd-common/

```
terraform init
terraform apply
```

---

## Next step

Set up [Terraform workflows](<https://km.oslo.systems/initial-setup-of-your-aws-environment/set-up-terraform-workflows/index.md>).
