[pkg-bacula-commits] [SCM] Bacula, a network backup, recovery and verification program branch, master, updated. debian/5.2.6+dfsg-1-7-g3c8cec3
Luca Capello
luca at pca.it
Wed Jun 27 14:36:44 UTC 2012
The following commit has been merged in the master branch:
commit 3c8cec3f3de2cfc51fc88dccea2174aa842ed006
Author: Luca Capello <luca at pca.it>
Date: Wed Jun 27 12:15:24 2012 +0200
debian/bacula-*.postinst: (#675227) replace *PASSWORD in config
diff --git a/debian/bacula-console-qt.postinst b/debian/bacula-console-qt.postinst
index fe2040c..240f6a4 100644
--- a/debian/bacula-console-qt.postinst
+++ b/debian/bacula-console-qt.postinst
@@ -27,6 +27,9 @@ SRCDIR="/usr/share/bacula-common/defconfig"
DSTDIR="/etc/bacula"
CFGFILE="bat.conf"
+. /usr/share/bacula-common/common-functions.dpkg
+readOrCreatePasswords
+
case "$1" in
configure)
@@ -37,7 +40,9 @@ case "$1" in
fi
# bconsole & wx-console use the same config file ;)
- sed -e "s~@debian_hostname@~localhost~" < $SRCDIR/$CFGFILE > $TARGET
+ sed -e "s~@debian_hostname@~localhost~" \
+ -e s~XXX_DIRPASSWORD_XXX~$DIRPASSWD~ \
+ < $SRCDIR/$CFGFILE > $TARGET
chown root:bacula $TARGET
chmod 640 $TARGET
diff --git a/debian/bacula-console.postinst b/debian/bacula-console.postinst
index 26acbb1..319fe7b 100644
--- a/debian/bacula-console.postinst
+++ b/debian/bacula-console.postinst
@@ -7,6 +7,9 @@ SRCDIR="/usr/share/bacula-common/defconfig"
DSTDIR="/etc/bacula"
CONFIG="bconsole.conf"
+. /usr/share/bacula-common/common-functions.dpkg
+readOrCreatePasswords
+
case "$1" in
configure)
if [ ! -f $DSTDIR/$CONFIG ]; then
@@ -15,7 +18,9 @@ case "$1" in
TARGET=$DSTDIR/$CONFIG.dist
fi
- sed -e "s~@debian_hostname@~localhost~" < $SRCDIR/$CONFIG > $TARGET
+ sed -e "s~@debian_hostname@~localhost~" \
+ -e s~XXX_DIRPASSWORD_XXX~$DIRPASSWD~ \
+ < $SRCDIR/$CONFIG > $TARGET
chown root:bacula $TARGET
chmod 640 $TARGET
diff --git a/debian/bacula-traymonitor.postinst b/debian/bacula-traymonitor.postinst
index 23a88e6..3ccef7b 100644
--- a/debian/bacula-traymonitor.postinst
+++ b/debian/bacula-traymonitor.postinst
@@ -27,6 +27,9 @@ SRCDIR="/usr/share/bacula-common/defconfig"
DSTDIR="/etc/bacula"
CONFIG="tray-monitor.conf"
+. /usr/share/bacula-common/common-functions.dpkg
+readOrCreatePasswords
+
case "$1" in
configure)
@@ -36,7 +39,12 @@ case "$1" in
TARGET=$DSTDIR/$CONFIG.dist
fi
- sed -e "s~@debian_hostname@~localhost~" < $SRCDIR/$CONFIG > $TARGET
+ sed -e "s~@debian_hostname@~localhost~" \
+ -e s~XXX_MONDIRPASSWORD_XXX~$DIRMPASSWD~ \
+ -e s~XXX_MONFDPASSWORD_XXX~$FDMPASSWD~ \
+ -e s~XXX_MONSDPASSWORD_XXX~$SDMPASSWD~ \
+ < $SRCDIR/$CONFIG > $TARGET
+
chown root:bacula $TARGET
chmod 640 $TARGET
diff --git a/debian/changelog b/debian/changelog
index f5a811f..5fbd66b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,10 @@ bacula (5.2.6+dfsg-2) UNRELEASED; urgency=low
* debian/bacula-console.postinst,
debian/bacula-traymonitor.postinst:
- remove useless CONSOLE variable.
+ * debian/bacula-console*.postinst,
+ debian/bacula-traymonitor.postinst:
+ + also replace *PASSWORD in config files, thanks to Richard
+ Hartmann <richih.mailinglist at gmail.com> (Closes: #675227).
* debian/bacula-director-*.postinst,
debian/bacula-fd.postinst, debian/bacula-sd.postinst:
+ move set call at the top.
--
Bacula, a network backup, recovery and verification program
More information about the pkg-bacula-commits
mailing list