Merge pull request #164 from MichaelConnolly98/load_dims_test_debugging #130
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
name: de-rossolimo-project | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
run-tests: | |
name: run-tests | |
runs-on: ubuntu-latest | |
env: | |
TZ: "Europe/London" | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@v4 | |
- name: Set-Up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.12' | |
- name: Set-up Postgres | |
uses: ikalnytskyi/action-setup-postgres@v6 | |
with: | |
username: ${{ secrets.PG_USER }} | |
password: ${{ secrets.PG_PASSWORD }} | |
database: test_totesys | |
port: 5432 | |
- name: Run Requirements | |
run: make requirements | |
- name: Run dev-setup | |
run: make dev-setup | |
- name: Run Tests | |
env: | |
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
AWS_DEFAULT_REGION: ${{ secrets.AWS_REGION }} | |
PG_USER: ${{ secrets.PG_USER }} | |
PG_PASSWORD: ${{ secrets.PG_PASSWORD }} | |
PG_DATABASE: test_totesys | |
PG_HOST: localhost | |
PG_PORT: 5432 | |
run: make run-checks | |
deploy-terraform: | |
name: deploy-all-terraform | |
runs-on: ubuntu-latest | |
needs: run-tests | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@v4 | |
- name: Install Terraform | |
uses: hashicorp/setup-terraform@v3 | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v4 | |
with: | |
aws-region: ${{ secrets.AWS_REGION }} | |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
- name: Init | |
working-directory: terraform | |
run: terraform init | |
- name: Plan | |
working-directory: terraform | |
env: | |
TF_VAR_emails: ${{ secrets.EMAIL }} | |
run: terraform plan | |
- name: Apply | |
working-directory: terraform | |
env: | |
TF_VAR_emails: ${{ secrets.EMAIL }} | |
run: terraform apply --auto-approve -input=false |