Skip to content

Commit

Permalink
resolve versioning issues in dbt-example
Browse files Browse the repository at this point in the history
  • Loading branch information
barend-xebia committed Dec 11, 2024
1 parent 83eb93e commit 4f064eb
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 4 deletions.
1 change: 1 addition & 0 deletions envs/dbt-example/.whirl.env
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ POSTGRES_USER=postgres
POSTGRES_DB=postgresdb

# DBT verbosity
DBT_VERSION=1.8.2
DBT_LOG_LEVEL=debug
DBT_LOG_FORMAT=text
DBT_LOG_FORMAT_FILE=text
Expand Down
4 changes: 3 additions & 1 deletion envs/dbt-example/whirl.setup.d/04_install_dbt.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
#!/usr/bin/env bash
sudo apt-get install -y libsasl2-dev build-essential
pip install dbt-core==1.7.5 airflow-dbt-python
pip install \
"dbt-core==${DBT_VERSION}" \
"airflow-dbt-python==2.1.0"

#airflow-dbt-python depends on the fs_default connection
echo "====================================="
Expand Down
3 changes: 2 additions & 1 deletion examples/dbt-example/.whirl.env
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
WHIRL_ENVIRONMENT=dbt-example
MOCK_DATA_FOLDER=${DAG_FOLDER}/mock-data
PYTHON_VERSION=3.8
PYTHON_VERSION=3.8
AIRFLOW_VERSION=2.8.0
10 changes: 8 additions & 2 deletions examples/dbt-example/whirl.setup.d/02_install_postgres_dbt.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
#!/usr/bin/env bash
pip install dbt-postgres==1.4.5
pip install \
"dbt-postgres==${DBT_VERSION}" \
"apache-airflow[spark,openlineage]==${AIRFLOW_VERSION}"

sudo chmod -R ugo+rw /opt/airflow/dags/dbt-example/dbt
sudo chmod -R ugo+rw /opt/airflow/dags/dbt-example/dbt

echo "-*=*==*====*==[dbt installation]==*===*==*=*-"
dbt --version
echo "-*=*==*====*======================*===*==*=*-"

0 comments on commit 4f064eb

Please sign in to comment.