3 # Parse all template files and expand them into real files
4 # Roland Mas, debian-sf (Sourceforge for Debian)
6 # For apache2 we have to remove the Listen 80 directive
7 # This is to test if apache2 is started and listen on port 80
9 # -dovhost will create vhosts
10 [ -f /etc/default/apache2 ] && . /etc/default/apache2
11 if [ "x$NO_START" = "x0" ]
13 /usr/share/gforge/bin/setup -fhs -noapache $@ -system pgsql -nolisten80
15 /usr/share/gforge/bin/setup -fhs -noapache $@ -system pgsql -listen80
18 [ -f /etc/gforge/local.inc ] && chmod 644 /etc/gforge/local.inc
19 [ -f /etc/gforge/httpd.conf ] && chmod 644 /etc/gforge/httpd.conf
21 [ -f /etc/gforge/database.inc ] && chown gforge:gforge /etc/gforge/database.inc
22 [ -f /etc/gforge/database.inc ] && chmod 640 /etc/gforge/database.inc
24 if getent group list > /dev/null
26 [ -f /etc/gforge/database.py ] && chgrp list /etc/gforge/database.py
28 [ -f /etc/gforge/database.py ] && chmod 640 /etc/gforge/database.py
30 [ -f /etc/gforge/local.pl ] && chmod go+rx /etc/gforge
31 [ -f /etc/gforge/local.pl ] && chown gforge:gforge /etc/gforge/local.pl
32 [ -f /etc/gforge/local.pl ] && chmod 640 /etc/gforge/local.pl
34 [ -f /etc/gforge/templates/httpd.conf.template ] && rm -f /etc/gforge/templates/*.template || true