Merge pull request 'entrypoint.sh aktualisiert' (#1) from main into devel

Reviewed-on: #1
This commit is contained in:
Marko Oldenburg 2024-09-26 11:40:12 +00:00
commit 3e728cdc53

View File

@ -13,7 +13,7 @@ echo "$PGHOST:5432:$PGDATABASE:$PGUSER:$PGPASSWORD" > ~/.pgpass
chmod 600 ~/.pgpass
# Optional: Standardwert für den Dateinamen der Sicherung
BACKUP_FILE=${BACKUP_FILE:-"/backup/db_backup_$(date +%Y%m%d_%H%M%S).sql"}
BACKUP_FILE=${BACKUP_FILE:-"/backup/$PGDATABASE_$(date +%Y%m%d_%H%M%S).sql"}
# Führe den pg_dump-Befehl aus (pg_dump wird automatisch die .pgpass-Datei verwenden)
pg_dump -h "$PGHOST" -U "$PGUSER" -d "$PGDATABASE" -F c -f "$BACKUP_FILE"