sync

Backup service to store encrypted wallet databases (experimental)
Log | Files | Refs | Submodules | README | LICENSE

commit d47e8423303a50d1ffaaa2a494f70b99d4c8da55
parent 52a09e2f719c023c8c728bdf6bd1e7a8b7fe051b
Author: Christian Grothoff <christian@grothoff.org>
Date:   Sat,  9 Sep 2023 15:05:23 +0200

improve Debian package

Diffstat:
Mdebian/sync-httpd.postinst | 8+++-----
Mdebian/sync-httpd.postrm | 4++++
2 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/debian/sync-httpd.postinst b/debian/sync-httpd.postinst @@ -31,11 +31,9 @@ configure) adduser --quiet --system --ingroup ${_GROUPNAME} --no-create-home --home ${SYNC_HOME} ${_USERNAME} fi - if ! dpkg-statoverride --list /etc/sync/secrets/sync-db.secret.conf >/dev/null 2>&1; then - dpkg-statoverride --add --update \ - sync-httpd root 460 \ - /etc/sync/secrets/sync-db.secret.conf - fi + dpkg-statoverride --add --update \ + sync-httpd root 640 \ + /etc/sync/secrets/sync-db.secret.conf ;; diff --git a/debian/sync-httpd.postrm b/debian/sync-httpd.postrm @@ -6,10 +6,14 @@ if [ -f /usr/share/debconf/confmodule ]; then . /usr/share/debconf/confmodule fi +_USERNAME=sync-httpd + case "${1}" in purge) rm -rf /var/lib/sync/httpd/ rm -f /etc/sync/override.conf + dpkg-statoverride --remove /etc/sync/secrets/sync-db.secret.conf + deluser --system --quiet ${_USERNAME} || true ;; remove | upgrade | failed-upgrade | abort-install | abort-upgrade | disappear) ;;