Revert "Modifying the default file is now useless"

This reverts commit cbe0da782042ba2d3df649c529f0891932366784.
This commit is contained in:
Benjamin Dauvergne 2015-03-03 17:54:19 +01:00
parent 4938ed51df
commit e5323f579f
1 changed files with 13 additions and 0 deletions

View File

@ -3,8 +3,21 @@
# Postinst script for authentic2-supann
#
add_supann_in_default() {
cat << EODEFAULT >> /etc/default/authentic2
if [ -r /etc/authentic2/supann.conf ]; then
. /etc/authentic2/supann.conf
fi
EODEFAULT
}
case "$1" in
configure|reconfigure)
if [ ! -f /etc/default/authentic2 ]; then
add_supann_in_default
elif ! grep -q supann.conf /etc/default/authentic2 2> /dev/null; then
add_supann_in_default
fi
invoke-rc.d authentic2 restart
;;
abort-upgrade|abort-remove|abort-deconfigure)