Commit 935ca45
build: bake postgresql-client + seed files into tripbot image (#473)
* build(tripbot): bake postgresql-client + seed files into the image
Adds postgresql-client to the runtime apt install, copies
infra/docker/bin/seed-db.sh to /usr/local/bin/seed-db, and copies
db/seed/ to /seed — prerequisites for the k8s seed Job that runs
the script in-cluster without a volume mount.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* fix(seed-db): remove runtime apt-install; add idempotency check
postgresql-client is now baked into the image, so the runtime
apt install is removed. The CSV path moves from the volume-mounted
repo path to /seed (in-image). Adds a row-count check so re-runs
against a non-empty videos table exit cleanly instead of failing.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* build(tripbot): install postgresql-client on-demand in seed script
Removes postgresql-client from the image's base apt install — it's
only needed by the one-time seed Job, so baking it into every
tripbot container is wasteful. The seed script installs it at runtime
with --no-install-recommends instead (leaner than the original
full postgresql package).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
* build: un-exclude infra/docker/bin from .dockerignore
The .dockerignore excluded all of infra/ (with only infra/docker/obs
carved back out). seed-db.sh lives in infra/docker/bin/ and needs to
be reachable by the COPY in the Dockerfile.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>1 parent af45f0f commit 935ca45
3 files changed
Lines changed: 16 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
4 | 5 | | |
5 | 6 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
6 | | - | |
7 | | - | |
8 | | - | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
31 | 35 | | |
32 | 36 | | |
33 | 37 | | |
| |||
0 commit comments