Add debian packaging files
This commit is contained in:
parent
06a58fed89
commit
28c1f6528c
|
@ -0,0 +1 @@
|
|||
9
|
|
@ -0,0 +1,14 @@
|
|||
Source: postgres-backup
|
||||
Section: unknown
|
||||
Priority: optional
|
||||
Maintainer: Cadoles <contact@cadoles.com>
|
||||
Build-Depends: debhelper (>= 8.0.0), dh-systemd (>= 1.5)
|
||||
Standards-Version: 3.9.4
|
||||
Homepage: http://forge.cadoles.com/Cadoles/postgres-backup
|
||||
Vcs-Git: http://forge.cadoles.com/Cadoles/postgres-backup.git
|
||||
Vcs-Browser: http://forge.cadoles.com/Cadoles/postgres-backup
|
||||
|
||||
Package: postgres-backup
|
||||
Architecture: amd64
|
||||
Depends: ${shlibs:Depends}, ${misc:Depends}
|
||||
Description: PostgreSQL backup scripts
|
|
@ -0,0 +1,3 @@
|
|||
/etc/postgres-backup/ /usr/share/postgres-backup/pg_backup.conf
|
||||
/usr/bin/ /usr/share/postgres-backup/pg_backup.sh
|
||||
/usr/bin/ /usr/share/postgres-backup/pg_backup_rotated.sh
|
|
@ -0,0 +1,9 @@
|
|||
[Unit]
|
||||
Description=Run PostgreSQL backup
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/usr/bin/pg_backup_rotated.sh
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
|
@ -0,0 +1,9 @@
|
|||
[Unit]
|
||||
Description=Timer for periodic execution of postgres-backup service.
|
||||
|
||||
[Timer]
|
||||
OnCalendar=daily
|
||||
Persistent=true
|
||||
|
||||
[Install]
|
||||
WantedBy=timers.target
|
|
@ -0,0 +1,24 @@
|
|||
#!/usr/bin/make -f
|
||||
# -*- makefile -*-
|
||||
|
||||
# Uncomment this to turn on verbose mode.
|
||||
export DH_VERBOSE=1
|
||||
|
||||
%:
|
||||
dh $@ --with systemd
|
||||
|
||||
override_dh_auto_install:
|
||||
mkdir -p debian/postgres-backup/usr/share/postgres-backup
|
||||
mkdir -p debian/postgres-backup/etc/postgres-backup
|
||||
mkdir -p debian/postgres-backup/usr/bin
|
||||
|
||||
cp script/pg_backup.sh debian/postgres-backup/usr/share/postgres-backup/pg_backup.sh
|
||||
cp script/pg_backup_rotated.sh debian/postgres-backup/usr/share/postgres-backup/pg_backup_rotated.sh
|
||||
cp conf/pg_backup.conf debian/postgres-backup/usr/share/postgres-backup/pg_backup.conf
|
||||
|
||||
chmod +x debian/postgres-backup/usr/share/postgres-backup/pg_backup_rotated.sh
|
||||
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 debian/postgres-backup
|
|
@ -0,0 +1 @@
|
|||
3.0 (native)
|
Loading…
Reference in New Issue