-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Split up ci/cd into different GHA workflows
- Loading branch information
Showing
4 changed files
with
109 additions
and
101 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
name: ci | ||
|
||
on: | ||
pull_request: | ||
branches: main | ||
|
||
jobs: | ||
terraform_mgmt: | ||
name: Check terraform files | ||
runs-on: ubuntu-latest | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
defaults: | ||
run: | ||
working-directory: "./terraform/mgmt" | ||
steps: | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v4 | ||
- | ||
name: Install terraform | ||
uses: hashicorp/setup-terraform@v3 | ||
with: | ||
terraform_version: "1.9.0" | ||
- | ||
name: Terraform fmt | ||
id: fmt | ||
run: terraform fmt -check | ||
- | ||
name: Initialize terraform | ||
run: terraform init | ||
- | ||
name: Terraform Validate | ||
id: validate | ||
run: terraform validate -no-color | ||
- | ||
name: Terraform Plan | ||
id: plan | ||
run: terraform plan -no-color | ||
|
||
docker: | ||
name: Run automated testing inside docker | ||
timeout-minutes: 5 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- | ||
name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v3 | ||
- | ||
name: Build and push jest tests | ||
uses: docker/build-push-action@v6 | ||
with: | ||
target: "test-jest" | ||
tags: test-jest | ||
load: true | ||
- | ||
name: Jest tests | ||
run: docker run --rm test-jest | ||
- | ||
name: Build and push playwright tests | ||
uses: docker/build-push-action@v6 | ||
with: | ||
target: "test-playwright" | ||
tags: test-playwright | ||
load: true | ||
- | ||
name: Playwright tests | ||
run: docker run --rm test-playwright | ||
|
||
terraform_prd: | ||
name: Check terraform files | ||
needs: terraform_mgmt | ||
runs-on: ubuntu-latest | ||
env: | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
defaults: | ||
run: | ||
working-directory: "./terraform/prd" | ||
steps: | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v4 | ||
- | ||
name: Install terraform | ||
uses: hashicorp/setup-terraform@v3 | ||
with: | ||
terraform_version: "1.9.0" | ||
- | ||
name: Terraform fmt | ||
id: fmt | ||
run: terraform fmt -check | ||
- | ||
name: Initialize terraform | ||
run: terraform init | ||
- | ||
name: Terraform Validate | ||
id: validate | ||
run: terraform validate -no-color | ||
- | ||
name: Terraform Plan | ||
id: plan | ||
run: terraform plan -no-color |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.