fix(pipeline): invoke dbt via python module to avoid Fusion shadowing
Build and Push Docker Images / Build Backend (FastAPI) (push) Successful in 53s
Build and Push Docker Images / Build Frontend (Next.js) (push) Successful in 56s
Build and Push Docker Images / Build Pipeline (Meltano + dbt + Airflow) (push) Successful in 2m0s
Build and Push Docker Images / Trigger Portainer Update (push) Successful in 1s

The standalone dbt Fusion binary (dbt-core 2.x) on PATH shadows the
pip-installed classic dbt-postgres ~=1.10 and rejects the Postgres
adapter (dbt1005), breaking every DAG's dbt_build task. Invoke dbt via
`python -m dbt.cli.main` in the DAGs and the Dockerfile dbt deps step so
the classic Postgres-capable engine is always used regardless of PATH.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Tudor
2026-06-18 13:41:35 +01:00
co-authored by Claude Opus 4.8
parent 87442788d4
commit 3785f0c977
2 changed files with 8 additions and 3 deletions
+3 -2
View File
@@ -32,8 +32,9 @@ COPY dags/ dags/
# Initialize Meltano project (generates catalog, installs target-postgres)
RUN meltano install
# dbt deps
RUN cd transform && dbt deps --profiles-dir . 2>/dev/null || true
# dbt deps — invoke via the Python module so the classic dbt-postgres engine
# is used, not a standalone dbt Fusion binary that may shadow it on PATH.
RUN cd transform && python -m dbt.cli.main deps --profiles-dir . 2>/dev/null || true
ENV AIRFLOW_HOME=/opt/airflow
ENV AIRFLOW__CORE__DAGS_FOLDER=/opt/pipeline/dags