chore: remove MongoDB service, packages and transfer tooling (MITHOME-136)

The staging site runs on PostgreSQL since 2026-09-29. Drop the mongodb
compose service/volume, the mongodb/mongoose/@payloadcms/db-mongodb
packages, the one-off transfer script and its helpers, the mongodump
block in deploy.sh and the Mongo jest mock. Docs updated.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
Do Siki
2026-10-03 21:16:55 +02:00
co-authored by Claude Sonnet 5.5
parent b3b0347787
commit e14a987bf3
22 changed files with 18 additions and 840 deletions
+1 -7
View File
@@ -62,7 +62,7 @@ fi
# 2b2. Adatbázis-mentés — build ELŐTT (MITHOME-111, MITHOME-136)
# WHY: a prodMigrations induláskor sémát módosíthat; egy hibás kiadás után
# a deploy előtti mentésből kell tudni visszaállni. Ami fut, azt mentjük:
# PostgreSQL (pg_dump, egyedi formátum) és — az átállás idejére — MongoDB.
# PostgreSQL (pg_dump, egyedi formátum).
CONTAINER_ENV="$ENV"
[ "$ENV" = "production" ] && CONTAINER_ENV="prod"
BACKUP_DIR="$HOME/backups"
@@ -75,12 +75,6 @@ if docker ps --format '{{.Names}}' | grep -qx "mozdit-postgres-${CONTAINER_ENV}"
chmod 600 "$PG_BACKUP"
echo "💾 PostgreSQL-mentés: $PG_BACKUP"
fi
if docker ps --format '{{.Names}}' | grep -qx "mozdit-mongodb-${CONTAINER_ENV}"; then
MONGO_BACKUP="$BACKUP_DIR/mozdit-${ENV}-${STAMP}-pre-deploy.archive"
docker exec "mozdit-mongodb-${CONTAINER_ENV}" sh -c 'mongodump --quiet --username "$MONGO_INITDB_ROOT_USERNAME" --password "$MONGO_INITDB_ROOT_PASSWORD" --authenticationDatabase admin --db mozdit --archive' > "$MONGO_BACKUP"
chmod 600 "$MONGO_BACKUP"
echo "💾 MongoDB-mentés: $MONGO_BACKUP"
fi
# 2c. Port-ellenőrzés — build ELŐTT, hogy egy ütközés ne egy teljes build után
# derüljön ki. A saját projekt (újraindítandó) konténerei által foglalt port