Create and set ownership to backup directory

This commit is contained in:
wpetit 2020-10-13 17:16:20 +02:00
parent e0e4cd71de
commit 3779002a3d
3 changed files with 5 additions and 1 deletions

1
debian/postgres-backup.dirs vendored Normal file
View File

@ -0,0 +1 @@
/var/backups/database/postgresql

4
debian/postgres-backup.postinst vendored Normal file
View File

@ -0,0 +1,4 @@
#!/bin/bash
mkdir -p /var/backups/database/postgresql
chown -R postgres:postgres /var/backups/database/postgresql

1
debian/rules vendored
View File

@ -20,6 +20,5 @@ override_dh_auto_install:
chmod +x debian/postgres-backup/usr/share/postgres-backup/pg_backup.sh
install -D -m 644 debian/postgres-backup.timer debian/postgres-backup/lib/systemd/system/postgres-backup.timer
install -d -o postgres -g postgres debian/postgres-backup/var/backups/database/postgresql
install -d debian/postgres-backup