Password prompts for MySQL adduser
[hcoop/domtool2.git] / scripts / domtool-publish
1 #!/bin/sh -e
2
3 case $1 in
4 apache)
5 /usr/bin/rsync -r --delete /var/domtool/vhosts/ /etc/apache2/vhosts/
6 /etc/init.d/apache2 reload
7 ;;
8 apache-down)
9 /etc/init.d/apache2 stop
10 ;;
11 apache-undown)
12 /usr/bin/rsync -r --delete /var/domtool/vhosts/ /etc/apache2/vhosts/
13 /etc/init.d/apache2 start
14 ;;
15 bind)
16 /usr/bin/rsync -r --delete /var/domtool/zones/ /etc/bind/zones/
17 /bin/cp /var/domtool/named.conf.local /etc/bind/
18 /etc/init.d/bind9 reload
19 ;;
20 exim)
21 /bin/cp /var/domtool/aliases /etc/
22 /bin/cp /var/domtool/aliases.default /etc/
23 /bin/cp /var/domtool/local_domains.cfg /etc/exim4/
24 /etc/init.d/exim4 reload
25 ;;
26 mailman)
27 /bin/cp /var/domtool/mailman.map /etc/mailman
28 /etc/init.d/mailman reload
29 ;;
30 *)
31 echo "Usage: domtool-publish [apache|bind|exim|mailman]"
32 ;;
33 esac