Skip to content

Commit

Permalink
update ci
Browse files Browse the repository at this point in the history
  • Loading branch information
bergalli committed Apr 29, 2024
1 parent 1b2b2ea commit 765e5c0
Showing 1 changed file with 33 additions and 2 deletions.
35 changes: 33 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,20 @@ jobs:
dbt-run:
needs: lint-sql
runs-on: ubuntu-latest
services:
postgres:
image: postgres:12
env:
POSTGRES_DB: dbt
POSTGRES_USER: user
POSTGRES_PASSWORD: password
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v2
Expand All @@ -37,6 +51,23 @@ jobs:
- name: Install dbt
run: pip install dbt

- name: Run dbt
run: dbt run
- name: Set up dbt profile
run: |
mkdir -p ~/.dbt
echo "config_version: 2
profiles.yml:
default:
target: dev
outputs:
dev:
type: postgres
threads: 1
host: localhost
port: 5432
user: user
pass: password
dbname: dbt
schema: public" > ~/.dbt/profiles.yml
- name: Run dbt
run: dbt run --profiles-dir ~/.dbt

0 comments on commit 765e5c0

Please sign in to comment.