Skip to content

Commit

Permalink
upgrade to dbt1.7, re-org workflow folder struct
Browse files Browse the repository at this point in the history
  • Loading branch information
desmond-hui committed Jan 4, 2024
1 parent cc14acf commit 869b1d0
Show file tree
Hide file tree
Showing 34 changed files with 230 additions and 503 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/dbt_alter_gha_tasks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ concurrency:

jobs:
called_workflow_template:
uses: FlipsideCrypto/analytics-workflow-templates/.github/workflows/dbt_alter_gha_tasks.yml@main
uses: |
FlipsideCrypto/analytics-workflow-templates/.github/workflows/dbt_alter_gha_tasks.yml@AN-4374/upgrade-dbt-1.7
with:
workflow_name: |
${{ inputs.workflow_name }}
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/dbt_docs_update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,6 @@ concurrency:

jobs:
called_workflow_template:
uses: FlipsideCrypto/analytics-workflow-templates/.github/workflows/dbt_docs_updates.yml@main
uses: |
FlipsideCrypto/analytics-workflow-templates/.github/workflows/dbt_alter_gha_tasks.yml@AN-4374/upgrade-dbt-1.7
secrets: inherit
21 changes: 11 additions & 10 deletions .github/workflows/dbt_run_adhoc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,16 @@ on:
required: true

env:
DBT_PROFILES_DIR: "${{ secrets.DBT_PROFILES_DIR }}"
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"

ACCOUNT: "${{ secrets.ACCOUNT }}"
ROLE: "${{ secrets.ROLE }}"
USER: "${{ secrets.USER }}"
ACCOUNT: "${{ vars.ACCOUNT }}"
ROLE: "${{ vars.ROLE }}"
USER: "${{ vars.USER }}"
PASSWORD: "${{ secrets.PASSWORD }}"
REGION: "${{ secrets.REGION }}"
DATABASE: "${{ secrets.DATABASE }}"
REGION: "${{ vars.REGION }}"
DATABASE: "${{ vars.DATABASE }}"
WAREHOUSE: "${{ inputs.warehouse }}"
SCHEMA: "${{ secrets.SCHEMA }}"
SCHEMA: "${{ vars.SCHEMA }}"


jobs:
Expand All @@ -52,13 +52,14 @@ jobs:
steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v1
- uses: actions/setup-python@v4
with:
python-version: "3.7.x"
python-version: "${{ vars.PYTHON_VERSION }}"
cache: "pip"

- name: install dependencies
run: |
pip3 install dbt-snowflake==${{ secrets.DBT_VERSION }} cli_passthrough requests click
pip3 install dbt-snowflake==${{ vars.DBT_VERSION }} cli_passthrough requests click
dbt deps
- name: Run DBT Jobs
run: |
Expand Down
21 changes: 11 additions & 10 deletions .github/workflows/dbt_run_batch_backfill.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@ on:
- cron: '*/7 * * * *'

env:
DBT_PROFILES_DIR: "${{ secrets.DBT_PROFILES_DIR }}"
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"

ACCOUNT: "${{ secrets.ACCOUNT }}"
ROLE: "${{ secrets.ROLE }}"
USER: "${{ secrets.USER }}"
ACCOUNT: "${{ vars.ACCOUNT }}"
ROLE: "${{ vars.ROLE }}"
USER: "${{ vars.USER }}"
PASSWORD: "${{ secrets.PASSWORD }}"
REGION: "${{ secrets.REGION }}"
DATABASE: "${{ secrets.DATABASE }}"
REGION: "${{ vars.REGION }}"
DATABASE: "${{ vars.DATABASE }}"
WAREHOUSE: DBT_EMERGENCY
SCHEMA: "${{ secrets.SCHEMA }}"
SCHEMA: "${{ vars.SCHEMA }}"
DBT_IS_BATCH_LOAD: true

concurrency:
Expand All @@ -32,13 +32,14 @@ jobs:
steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v1
- uses: actions/setup-python@v4
with:
python-version: "3.7.x"
python-version: "${{ vars.PYTHON_VERSION }}"
cache: "pip"

- name: install dependencies
run: |
pip3 install dbt-snowflake==${{ secrets.DBT_VERSION }} cli_passthrough requests click
pip3 install dbt-snowflake==${{ vars.DBT_VERSION }} cli_passthrough requests click
dbt deps
- name: Run DBT Jobs
run: |
Expand Down
23 changes: 12 additions & 11 deletions .github/workflows/dbt_run_daily.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ on:
- cron: '35 0 * * *'

env:
DBT_PROFILES_DIR: "${{ secrets.DBT_PROFILES_DIR }}"
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"

ACCOUNT: "${{ secrets.ACCOUNT }}"
ROLE: "${{ secrets.ROLE }}"
USER: "${{ secrets.USER }}"
ACCOUNT: "${{ vars.ACCOUNT }}"
ROLE: "${{ vars.ROLE }}"
USER: "${{ vars.USER }}"
PASSWORD: "${{ secrets.PASSWORD }}"
REGION: "${{ secrets.REGION }}"
DATABASE: "${{ secrets.DATABASE }}"
WAREHOUSE: "${{ secrets.WAREHOUSE }}"
SCHEMA: "${{ secrets.SCHEMA }}"
REGION: "${{ vars.REGION }}"
DATABASE: "${{ vars.DATABASE }}"
WAREHOUSE: "${{ vars.WAREHOUSE }}"
SCHEMA: "${{ vars.SCHEMA }}"

concurrency:
group: ${{ github.workflow }}
Expand All @@ -30,13 +30,14 @@ jobs:
steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v1
- uses: actions/setup-python@v4
with:
python-version: "3.7.x"
python-version: "${{ vars.PYTHON_VERSION }}"
cache: "pip"

- name: install dependencies
run: |
pip3 install dbt-snowflake==${{ secrets.DBT_VERSION }} cli_passthrough requests click
pip3 install dbt-snowflake==${{ vars.DBT_VERSION }} cli_passthrough requests click
dbt deps
- name: Run DBT Jobs
run: |
Expand Down
18 changes: 9 additions & 9 deletions .github/workflows/dbt_run_deploy_udfs_and_sps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,16 +9,16 @@ on:
- 'macros/**'

env:
DBT_PROFILES_DIR: "${{ secrets.DBT_PROFILES_DIR }}"
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"

ACCOUNT: "${{ secrets.ACCOUNT }}"
ROLE: "${{ secrets.ROLE }}"
USER: "${{ secrets.USER }}"
ACCOUNT: "${{ vars.ACCOUNT }}"
ROLE: "${{ vars.ROLE }}"
USER: "${{ vars.USER }}"
PASSWORD: "${{ secrets.PASSWORD }}"
REGION: "${{ secrets.REGION }}"
DATABASE: "${{ secrets.DATABASE }}"
WAREHOUSE: "${{ secrets.WAREHOUSE }}"
SCHEMA: "${{ secrets.SCHEMA }}"
REGION: "${{ vars.REGION }}"
DATABASE: "${{ vars.DATABASE }}"
WAREHOUSE: "${{ vars.WAREHOUSE }}"
SCHEMA: "${{ vars.SCHEMA }}"

concurrency:
group: ${{ github.workflow }}
Expand All @@ -39,7 +39,7 @@ jobs:

- name: install dependencies
run: |
pip3 install dbt-snowflake==${{ secrets.DBT_VERSION }} cli_passthrough requests click
pip3 install dbt-snowflake==${{ vars.DBT_VERSION }} cli_passthrough requests click
dbt deps
- name: Run DBT Jobs
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/dbt_run_deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ concurrency:

jobs:
called_workflow_template:
uses: FlipsideCrypto/analytics-workflow-templates/.github/workflows/dbt_run_deployment_template.yml@main
uses: |
FlipsideCrypto/analytics-workflow-templates/.github/workflows/dbt_alter_gha_tasks.yml@AN-4374/upgrade-dbt-1.7
with:
dbt_command: |
${{ inputs.dbt_command }}
Expand Down
23 changes: 12 additions & 11 deletions .github/workflows/dbt_run_dev_refresh.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@ on:
- cron: '0 6 * * *'

env:
DBT_PROFILES_DIR: "${{ secrets.DBT_PROFILES_DIR }}"
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"

ACCOUNT: "${{ secrets.ACCOUNT }}"
ROLE: "${{ secrets.ROLE }}"
USER: "${{ secrets.USER }}"
ACCOUNT: "${{ vars.ACCOUNT }}"
ROLE: "${{ vars.ROLE }}"
USER: "${{ vars.USER }}"
PASSWORD: "${{ secrets.PASSWORD }}"
REGION: "${{ secrets.REGION }}"
DATABASE: "${{ secrets.DATABASE }}"
WAREHOUSE: "${{ secrets.WAREHOUSE }}"
SCHEMA: "${{ secrets.SCHEMA }}"
REGION: "${{ vars.REGION }}"
DATABASE: "${{ vars.DATABASE }}"
WAREHOUSE: "${{ vars.WAREHOUSE }}"
SCHEMA: "${{ vars.SCHEMA }}"

concurrency:
group: ${{ github.workflow }}
Expand All @@ -31,13 +31,14 @@ jobs:
steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v1
- uses: actions/setup-python@v4
with:
python-version: "3.7.x"
python-version: "${{ vars.PYTHON_VERSION }}"
cache: "pip"

- name: install dependencies
run: |
pip3 install dbt-snowflake==${{ secrets.DBT_VERSION }} cli_passthrough requests click
pip3 install dbt-snowflake==${{ vars.DBT_VERSION }} cli_passthrough requests click
dbt deps
- name: Run DBT Jobs
run: |
Expand Down
23 changes: 12 additions & 11 deletions .github/workflows/dbt_run_incremental.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ on:
- "main"

env:
DBT_PROFILES_DIR: "${{ secrets.DBT_PROFILES_DIR }}"
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"

ACCOUNT: "${{ secrets.ACCOUNT }}"
ROLE: "${{ secrets.ROLE }}"
USER: "${{ secrets.USER }}"
ACCOUNT: "${{ vars.ACCOUNT }}"
ROLE: "${{ vars.ROLE }}"
USER: "${{ vars.USER }}"
PASSWORD: "${{ secrets.PASSWORD }}"
REGION: "${{ secrets.REGION }}"
DATABASE: "${{ secrets.DATABASE }}"
WAREHOUSE: "${{ secrets.WAREHOUSE }}"
SCHEMA: "${{ secrets.SCHEMA }}"
REGION: "${{ vars.REGION }}"
DATABASE: "${{ vars.DATABASE }}"
WAREHOUSE: "${{ vars.WAREHOUSE }}"
SCHEMA: "${{ vars.SCHEMA }}"

concurrency:
group: ${{ github.workflow }}
Expand All @@ -30,13 +30,14 @@ jobs:
steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v1
- uses: actions/setup-python@v4
with:
python-version: "3.7.x"
python-version: "${{ vars.PYTHON_VERSION }}"
cache: "pip"

- name: install dependencies
run: |
pip3 install dbt-snowflake==${{ secrets.DBT_VERSION }} cli_passthrough requests click
pip3 install dbt-snowflake==${{ vars.DBT_VERSION }} cli_passthrough requests click
dbt deps
- name: Run DBT Jobs
run: |
Expand Down
23 changes: 12 additions & 11 deletions .github/workflows/dbt_run_incremental_non_core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@ on:
# - cron: "20,50 * * * *"

env:
DBT_PROFILES_DIR: "${{ secrets.DBT_PROFILES_DIR }}"
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"

ACCOUNT: "${{ secrets.ACCOUNT }}"
ROLE: "${{ secrets.ROLE }}"
USER: "${{ secrets.USER }}"
ACCOUNT: "${{ vars.ACCOUNT }}"
ROLE: "${{ vars.ROLE }}"
USER: "${{ vars.USER }}"
PASSWORD: "${{ secrets.PASSWORD }}"
REGION: "${{ secrets.REGION }}"
DATABASE: "${{ secrets.DATABASE }}"
WAREHOUSE: "${{ secrets.WAREHOUSE }}"
SCHEMA: "${{ secrets.SCHEMA }}"
REGION: "${{ vars.REGION }}"
DATABASE: "${{ vars.DATABASE }}"
WAREHOUSE: "${{ vars.WAREHOUSE }}"
SCHEMA: "${{ vars.SCHEMA }}"

concurrency:
group: ${{ github.workflow }}
Expand All @@ -31,13 +31,14 @@ jobs:
steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v1
- uses: actions/setup-python@v4
with:
python-version: "3.7.x"
python-version: "${{ vars.PYTHON_VERSION }}"
cache: "pip"

- name: install dependencies
run: |
pip3 install dbt-snowflake==${{ secrets.DBT_VERSION }} cli_passthrough requests click
pip3 install dbt-snowflake==${{ vars.DBT_VERSION }} cli_passthrough requests click
dbt deps
- name: Run DBT Jobs
run: |
Expand Down
23 changes: 12 additions & 11 deletions .github/workflows/dbt_run_macro_get_block_production.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ on:
- cron: '0 */4 * * *'

env:
DBT_PROFILES_DIR: "${{ secrets.DBT_PROFILES_DIR }}"
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"

ACCOUNT: "${{ secrets.ACCOUNT }}"
ROLE: "${{ secrets.ROLE }}"
USER: "${{ secrets.USER }}"
ACCOUNT: "${{ vars.ACCOUNT }}"
ROLE: "${{ vars.ROLE }}"
USER: "${{ vars.USER }}"
PASSWORD: "${{ secrets.PASSWORD }}"
REGION: "${{ secrets.REGION }}"
DATABASE: "${{ secrets.DATABASE }}"
WAREHOUSE: "${{ secrets.WAREHOUSE }}"
SCHEMA: "${{ secrets.SCHEMA }}"
REGION: "${{ vars.REGION }}"
DATABASE: "${{ vars.DATABASE }}"
WAREHOUSE: "${{ vars.WAREHOUSE }}"
SCHEMA: "${{ vars.SCHEMA }}"

concurrency:
group: ${{ github.workflow }}
Expand All @@ -30,13 +30,14 @@ jobs:
steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v1
- uses: actions/setup-python@v4
with:
python-version: "3.7.x"
python-version: "${{ vars.PYTHON_VERSION }}"
cache: "pip"

- name: install dependencies
run: |
pip3 install dbt-snowflake==${{ secrets.DBT_VERSION }} cli_passthrough requests click
pip3 install dbt-snowflake==${{ vars.DBT_VERSION }} cli_passthrough requests click
dbt deps
- name: Run DBT Jobs
run: |
Expand Down
Loading

0 comments on commit 869b1d0

Please sign in to comment.