Skip to content

chore(main): Release transformation-aws-data-resilience v1.2.0 (#387) #76

chore(main): Release transformation-aws-data-resilience v1.2.0 (#387)

chore(main): Release transformation-aws-data-resilience v1.2.0 (#387) #76

name: "Test AWS Data Resilience Policies: Postgres"
on:
pull_request:
paths:
- "transformations/aws/data-resilience/**"
- ".github/workflows/transformations_aws_data_resilience_postgres.yml"
- "transformations/aws/macros/**"
- "transformations/aws/models/**"
- "transformations/macros/**"
push:
branches:
- main
paths:
- "transformations/aws/data-resilience/**"
- ".github/workflows/transformations_aws_data_resilience_postgres.yml"
- "transformations/aws/macros/**"
- "transformations/aws/models/**"
- "transformations/macros/**"
jobs:
transformations-aws-data-resilience:
name: transformations/aws/data-resilience
timeout-minutes: 30
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./transformations/aws/data-resilience
services:
postgres:
image: postgres:11
env:
POSTGRES_PASSWORD: pass
POSTGRES_USER: postgres
POSTGRES_DB: postgres
ports:
- 5432:5432
# Set health checks to wait until postgres has started
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: "3.9"
cache: "pip"
cache-dependency-path: "./transformations/aws/data-resilience/requirements.txt"
- name: Install dependencies
run: pip install -r requirements.txt
- name: Setup CloudQuery
uses: cloudquery/setup-cloudquery@v3
with:
version: v4.3.1
- name: Migrate DB
run: cloudquery migrate tests/postgres.yml
env:
CQ_DSN: postgresql://postgres:pass@localhost:5432/postgres
- name: Run Policies
run: |
dbt run --target dev-pg --profiles-dir ./tests