]> git.decadent.org.uk Git - memories.git/blob - debian/memories.postinst
Remove installation of Apache config fragment from rules.
[memories.git] / debian / memories.postinst
1 #!/bin/sh
2
3 if [ "x$1" = xconfigure ]; then
4
5     # Install our configuration fragment and make Apache load it
6     # (and unload any code from a previous version of Memories).
7     # Check whether mod_perl is enabled first.
8     for server in apache apache-perl apache-ssl; do
9         if [ "$(apache-modconf $server query mod_perl 2>/dev/null)" \
10                  = "mod_perl" -a \
11              \! -e /etc/$server/conf.d/memories ]; then
12             ln -s ../../memories/apache.conf /etc/$server/conf.d/memories
13             invoke-rc.d $server force-reload
14         fi
15     done
16     # Module configuration is different in the apache2 package.
17     if [ -e /etc/apache2/mods-enabled/perl.load -a \
18          \! -e /etc/apache2/conf.d/memories ]; then
19         ln -s ../../memories/apache.conf /etc/apache2/conf.d/memories
20         invoke-rc.d apache2 force-reload
21     fi
22
23 fi