diff --git a/debian/postinst b/debian/postinst index c836e517..07d7f1e3 100644 --- a/debian/postinst +++ b/debian/postinst @@ -157,6 +157,13 @@ EOF . $CONFIGFILE fi + # /var/alternc/dns/d/www.example.com + FQDN_LETTER="`echo $FQDN | sed -e 's/.*\.\([^\.]\)[^\.]*\.[^\.]*$/\1/'`" + if [ "$FQDN_LETTER" = "$FQDN" ] + then + FQDN_LETTER="_" + fi + # Erase all apacheconf file # They will be regenerated without the bug by upgrade_check.sh below. if dpkg --compare-versions "$2" le "0.9.3.9-globenet14"; then @@ -174,6 +181,21 @@ EOF echo "" >> $pma_config fi + # Add access to the management panel + ln -nsf /var/alternc/bureau /var/alternc/dns/$FQDN_LETTER/$FQDN + + # Bind stuff + touch /var/alternc/bind/automatic.conf /var/alternc/bind/slaveip.conf + chown root:bind /var/alternc/bind/automatic.conf /var/alternc/bind/slaveip.conf + chmod 640 /var/alternc/bind/automatic.conf /var/alternc/bind/slaveip.conf + touch /var/run/alternc/refresh_slave + /usr/lib/alternc/slave_dns + # Apache will not start without this file + touch /var/alternc/apacheconf/override_php.conf + + # Update l18n files + /usr/share/alternc/install/dopo.sh + # important: postinst gele sans ca db_stop diff --git a/install/alternc.install b/install/alternc.install index f430b7e9..11de2bf4 100644 --- a/install/alternc.install +++ b/install/alternc.install @@ -181,21 +181,7 @@ tar -zcf "$INSTALLED_CONFIG_TAR" -C / $CONFIG_FILES ######################################################################## # Ad-hoc fixes # -# Add access to the management panel -ln -nsf /var/alternc/bureau /var/alternc/dns/$FQDN_LETTER/$FQDN -# Update l18n files -/usr/share/alternc/install/dopo.sh - -# Bind stuff -touch /var/alternc/bind/automatic.conf /var/alternc/bind/slaveip.conf -chown root:bind /var/alternc/bind/automatic.conf /var/alternc/bind/slaveip.conf -chmod 640 /var/alternc/bind/automatic.conf /var/alternc/bind/slaveip.conf -touch /var/run/alternc/refresh_slave -/usr/lib/alternc/slave_dns - -# Apache will not start without this file -touch /var/alternc/apacheconf/override_php.conf php="`ls /usr/lib/apache*/*/*php*.so | sed -e 's/^.*libphp\(.\)\.so$/php\1/' | tail -1`" if [ -x /usr/sbin/apache ] then