Add immich as gallery

This commit is contained in:
Tobias Reisinger 2024-01-06 20:43:40 +01:00
parent 6574543759
commit 24d93ecad6
Signed by: serguzim
GPG key ID: 13AD60C237A28DFE
7 changed files with 116 additions and 2 deletions

View file

@ -0,0 +1,5 @@
backup_path="$BACKUP_LOCATION/immich"
mkdir -p "$backup_path"
cd /opt/services/immich || exit
docker compose exec database pg_dump -U "$DB_USERNAME" "$DB_DATABASE" | gzip >"$backup_path/immich.sql.gz"

View file

@ -6,9 +6,9 @@ postgres_tables=$(sudo -u postgres psql -Atc "SELECT datname FROM pg_database WH
for i in $postgres_tables
do
printf "dumping %s ..." "$i"
sudo -u postgres pg_dump "$i" | gzip >"pg_dump_$i.gz"
sudo -u postgres pg_dump "$i" | gzip >"pg_dump_$i.sql.gz"
echo " done"
done
echo "dumping all"
sudo -u postgres pg_dumpall | gzip >"pg_dumpall.gz"
sudo -u postgres pg_dumpall | gzip >"pg_dumpall.sql.gz"