infrastructure/playbooks/roles/backup/files/hooks/immich_database
Tobias Reisinger 4104057771
Fix pre-commit hooks and move directories
roles/ and inventory/ are now in playbooks/
also fixed issues reported by ansible-lint
2024-10-14 18:31:36 +02:00

6 lines
186 B
Bash
Executable file

#!/usr/bin/env bash
backup_path="$1"
cd /opt/services/immich || exit
docker compose exec database sh -c 'pg_dump -U "$DB_USERNAME" "$DB_DATABASE"' | gzip >"$backup_path/immich.sql.gz"