Skip to content

Commit 26bdb66

Browse files
committed
Add logic to use environments
1 parent 53a488b commit 26bdb66

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

.github/workflows/test-warehouse.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,10 +110,16 @@ jobs:
110110
dbt deps --project-dir dbt_project
111111
pip install -r requirements.txt
112112
113+
- name: Approval notice
114+
run: |
115+
echo "Your PR needs to be approved to run on the dwh_tests environment before this workflow can continue"
116+
113117
- name: Write dbt profiles
118+
environment: dwh_tests # This is a github environment (not to be confused with env vars)
114119
env:
115120
PROFILES_YML: ${{ secrets.CI_PROFILES_YML }}
116121
run: |
122+
echo "Setting profiles.yml (using secret from the dwh_tests environment)"
117123
mkdir -p ~/.dbt
118124
DBT_VERSION=$(pip show dbt-core | grep -i version | awk '{print $2}' | sed 's/\.//g')
119125
UNDERSCORED_REF_NAME=$(echo "${{ inputs.warehouse-type }}_dbt_${DBT_VERSION}_${BRANCH_NAME}" | awk '{print tolower($0)}' | head -c 40 | sed "s/-/_/g")

0 commit comments

Comments
 (0)