fix(ci): recreate named compose containers without collisions

CI ran `compose up --force-recreate` without the ingest profile, so
compose tried to *create* osint-dashboard while the old name-pinned
container was still running. down + rm -f the known names, then up
--profile ingest. Volumes stay.
This commit is contained in:
Sirius DevOps 2026-08-28 20:35:31 -04:00
commit f6505ed401
2 changed files with 49 additions and 1 deletions

View file

@ -141,7 +141,13 @@ jobs:
# osint-dashboard_osint-pgdata (pinned by `name:` in compose).
docker compose build --no-cache app ingester camera-service news-scraper news-summarizer || \
docker compose build app ingester camera-service news-scraper news-summarizer
docker compose up -d --force-recreate
# Name-pinned containers (container_name: osint-dashboard, …) collide
# when compose tries to create instead of recreate — e.g. leftover from
# a different working_dir or a half-failed previous up. down + rm -f
# the known names, then up the full ingest profile.
chmod +x scripts/compose-reup.sh
COMPOSE_PROJECT_NAME=osint-dashboard COMPOSE_PROFILES=ingest \
scripts/compose-reup.sh
docker image prune -f
echo "osint-dashboard deployed; images also on ${PUB}/${OWN}/"