From c76c8c71fa9e3106dcf2431144e58466113af654 Mon Sep 17 00:00:00 2001 From: Jameson Graef Rollins Date: Sat, 11 Oct 2008 15:56:18 -0400 Subject: [PATCH] fix the *inst scripts to properly handle linking in the gpg.conf files. --- debian/monkeysphere.postinst | 4 ++-- debian/monkeysphere.preinst | 6 +++++- src/monkeysphere-server | 2 +- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/debian/monkeysphere.postinst b/debian/monkeysphere.postinst index 0e36186..27a50e0 100755 --- a/debian/monkeysphere.postinst +++ b/debian/monkeysphere.postinst @@ -20,9 +20,9 @@ fi # install host gnupg home directory install --owner root --group monkeysphere --mode 750 -d "$VARLIB"/gnupg-host # link in the gpg.conf -ln -sf "$ETC"/gnupg-host.conf "$VARLIB"/gnupg-host/gpg.conf +ln -sTf "$ETC"/gpg-host.conf "$VARLIB"/gnupg-host/gpg.conf # install authentication gnupg home directory install --owner monkeysphere --group monkeysphere --mode 700 -d "$VARLIB"/gnupg-authentication # link in the gpg.conf -ln -sf "$ETC"/gnupg-authentication.conf "$VARLIB"/gnupg-authentication/gpg.conf +ln -sTf "$ETC"/gpg-authentication.conf "$VARLIB"/gnupg-authentication/gpg.conf diff --git a/debian/monkeysphere.preinst b/debian/monkeysphere.preinst index bfa6a91..860286b 100755 --- a/debian/monkeysphere.preinst +++ b/debian/monkeysphere.preinst @@ -12,7 +12,11 @@ VARLIB="/var/lib/monkeysphere" # /etc, where they will be linked back into the GNUPGHOMEs later if [ -f "$VARLIB"/gnupg-host/gpg.conf -a ! -L "$VARLIB"/gnupg-host/gpg.conf ] ; then mv "$VARLIB"/gnupg-host/gpg.conf "$ETC"/gpg-host.conf + chown root:root "$ETC"/gpg-host.conf + ln -s "$ETC"/gpg-host.conf "$VARLIB"/gnupg-host/gpg.conf fi if [ -f "$VARLIB"/gnupg-authentication/gpg.conf -a ! -L "$VARLIB"/gnupg-authentication/gpg.conf ] ; then - mv "$VARLIB"/gnupg-authentication/gpg.conf "$ETC"/gnupg-authentication.conf + mv "$VARLIB"/gnupg-authentication/gpg.conf "$ETC"/gpg-authentication.conf + chown root:root "$ETC"/gpg-authentication.conf + ln -s "$ETC"/gpg-authentication.conf "$VARLIB"/gnupg-authentication/gpg.conf fi diff --git a/src/monkeysphere-server b/src/monkeysphere-server index 324a273..60a83af 100755 --- a/src/monkeysphere-server +++ b/src/monkeysphere-server @@ -17,7 +17,7 @@ SYSSHAREDIR=${MONKEYSPHERE_SYSSHAREDIR:-"/usr/share/monkeysphere"} export SYSSHAREDIR . "${SYSSHAREDIR}/common" || exit 1 -SYSDATADIR=${MONKEYSPHERE_SYSDATADIR:-"/var/lib/monkeysphere" +SYSDATADIR=${MONKEYSPHERE_SYSDATADIR:-"/var/lib/monkeysphere"} export SYSDATADIR # UTC date in ISO 8601 format if needed -- 2.25.1