Fix broken build, replace the unmaintained Sakila image, add Codespaces - #1
Open
jvanbuel wants to merge 1 commit into
Open
Fix broken build, replace the unmaintained Sakila image, add Codespaces#1jvanbuel wants to merge 1 commit into
jvanbuel wants to merge 1 commit into
Conversation
jvanbuel
force-pushed
the
fix/modernize-stack
branch
2 times, most recently
from
August 11, 2026 12:35
22292bf to
3a850ce
Compare
jvanbuel
force-pushed
the
fix/modernize-stack
branch
from
August 11, 2026 12:40
3a850ce to
58be010
Compare
The image failed to build at the first README command. python:3.10-slim-buster is EOL and its apt repositories now 404, so 'docker compose build' died on the apt-get step. That step installed no packages at all, so it is removed rather than repaired. - Dockerfile: python:3.12-slim, dbt-postgres 1.3.1 -> 1.11.0 (dbt-core 1.12). Drop the no-op apt-get layer and the pytz pin, which current dbt resolves. - Dockerfile.postgres: replace frantiseks/postgres-sakila, unmaintained and amd64-only, with the official postgres:18 image preloaded with Pagila. The SQL is fetched at build time via ADD, so nothing is vendored here and moving release is a one-line change to PAGILA_TAG. Pinned to pagila-v4.0.0: v4.1.0 needs pgvector, which the official image does not carry. - docker-compose.yml: healthcheck now checks TCP. The socket check went green while the entrypoint's temporary socket-only server was still loading, so dbt could start before Postgres accepted connections. - docker-compose.yml: drop the obsolete top-level 'version' key. - Snapshot block was named int_stock_balances_daily_grouped_by_day_snapshot while the file and _snapshots.yml both said int_customers_per_store_snapshot. Its not_null test therefore never ran. Renamed to match, taking the suite from 8 data tests to 9. - Add .devcontainer/devcontainer.json and a Codespaces badge. Docker-in-docker plus 'docker compose up -d --build' on create, so the models are built by the time the editor opens. - dbt_utils 1.0.0 -> 1.4.1. Untrack .DS_Store, add .gitignore. - README: docker compose instead of docker-compose, correct the snapshot name in the example queries, use container names instead of the docker ps id lookup, document what the project builds, drop the credit banner, and use Dataminded as one word. Verified: postgres service builds clean and dbt build passes 15/15 with no warnings. The dbt image build itself is NOT verified: Docker Hub is unreachable from this machine, so python:3.12-slim could not be pulled.
jvanbuel
force-pushed
the
fix/modernize-stack
branch
from
August 11, 2026 12:52
58be010 to
6dedced
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The repo does not build
docker compose build, the first command in the README, fails:python:3.10-slim-busteris EOL and its apt repositories now return 404. Theapt-getlayer that fails installs no packages at all (--no-install-recommendswith an empty package list), so this removes it rather than repairing it.This matters more than the commit count suggests: dbt-docker draws 321 views over the last four months, roughly half of all traffic across the org's 40 public repos, and it is the only repo pulling meaningful cold discovery traffic. Everyone arriving has been landing on a broken first command.
Changes
Dockerfilepython:3.12-slim; dbt-postgres1.3.1→1.11.0(dbt-core 1.12); dead apt layer andpytzpin removeddocker-compose.ymlfrantiseks/postgres-sakila→ officialpostgres:17+ Pagila; TCP healthcheck; obsoleteversion:key droppedsnapshots/int_customers_per_store_snapshot.sqlpackages.yml1.0.0→1.4.1README.mddocker compose, corrected snapshot name, container names instead ofdocker pslookupdb/pagila-v3.1.0vendored, 2.9 MBReplacing the Sakila image
frantiseks/postgres-sakilais unmaintained and amd64-only, so every Apple Silicon user ran it under emulation. This switches to the officialpostgres:18image preloaded with Pagila, the maintained Postgres port of Sakila.Nothing is vendored.
Dockerfile.postgresfetches the SQL at build time withADD, so the repository keeps a URL instead of 13 MB of generated SQL, and changing dataset is a one-line edit toPAGILA_TAG. Files added from a URL are not world-readable by default, hence--chmod=644: the entrypoint reads them as the postgres user.Pinned to
pagila-v4.0.0, released 2026-07-28. The latest tag, v4.1.0, adds columns requiring thepgvectorextension, which the official Postgres image does not carry. v4.0.0 needs no extensions at all, only PostgreSQL 18 foruuidv7().Upstream health: 1099 stars, last push 5 days ago, 18 commits in 2026, 3 open issues, maintained since 2015 by Devrim Gunduz, who packages PostgreSQL for the Red Hat family. Single-maintainer, which is normal for a sample database.
A test that never ran
The snapshot block was named
int_stock_balances_daily_grouped_by_day_snapshotwhile the file and_snapshots.ymlboth declaredint_customers_per_store_snapshot. dbt warned that it could not find the node, so that snapshot'snot_nulltest never executed. Renaming to match takes the suite from 8 data tests to 9. The wrong name appeared in the README example queries too.Healthcheck
The healthcheck now runs over TCP. While the seed files load, the Postgres entrypoint runs a temporary server bound to the unix socket only, so a socket check reports healthy while TCP connections are still refused and dbt fails to connect on startup.
Codespaces
Adds
.devcontainer/devcontainer.jsonand the badge, following the pattern already used byskill-boost-exposing-apis: docker-in-docker plusdocker compose up -d --buildon create, so the models are built by the time the editor opens. Postgres is forwarded on 5430. The three VS Code extension IDs were checked against the marketplace.Verification
The postgres service builds from scratch and
dbt buildagainst it: PASS=15, WARN=0, ERROR=0. All six README example queries return sensible rows (51,061 payments, 599 seeded customers, 1,619 revenue dates).One gap: the Docker image build itself is unverified. Docker Hub was unreachable from the machine this was prepared on, so
python:3.12-slimnever pulled. The dbt half was tested by running dbt-postgres 1.11 directly against the container, which covers the real risk in an 8-version jump. The deprecations expected aroundtests:andinvalidate_hard_deletesturned out clean. Please confirm with onedocker compose up --buildbefore merging.