Squirrelmail is only (for now) a simple specific domaintype. NEED TESTING

This commit is contained in:
Benjamin Sonntag 2012-08-26 20:46:32 +00:00
parent 4a096f265c
commit a8b05e045c
7 changed files with 1 additions and 82 deletions

3
.gitattributes vendored
View File

@ -502,9 +502,6 @@ selenium/20120826-alternc-panel-testsuite.html -text
selenium/README -text
selenium/alternc.domain-local-mail-tld.html -text
squirrelmail/Makefile -text
squirrelmail/apache-panel.d/squirrelmail.conf -text
squirrelmail/apache2.conf -text
squirrelmail/redirect.php -text
squirrelmail/squirrelmail-install -text
squirrelmail/templates/apache2/squirrelmail.conf -text
squirrelmail/templates/javascript-common/javascript-common.conf -text

View File

@ -1,11 +1,6 @@
etc/apache2/conf.d
etc/alternc
etc/alternc/apache-panel.d
etc/alternc/templates/squirrelmail
etc/alternc/templates/apache2
etc/alternc/templates/javascript-common
etc/cron.d
etc/squirrelmail
usr/share/alternc/install
usr/lib/alternc/install.d
usr/share/alternc-squirrelmail

View File

@ -25,10 +25,5 @@ install:
install -m 644 templates/squirrelmail/* $(DESTDIR)/etc/alternc/templates/squirrelmail/
install -m 644 templates/javascript-common/* $(DESTDIR)/etc/alternc/templates/javascript-common/
install -m 750 squirrelmail-install $(DESTDIR)/usr/lib/alternc/install.d/
install -m 644 apache-panel.d/squirrelmail.conf $(DESTDIR)/etc/alternc/apache-panel.d/
# default webmail vhost: squirrelmail.local, will be proxified from http://panel/squirrel/
install -m 644 apache2.conf $(DESTDIR)/etc/apache2/conf.d/alternc-squirrelmail.conf
# domaintype template:
install -m 644 templates/apache2/squirrelmail.conf $(DESTDIR)/etc/alternc/templates/apache2/squirrelmail.conf
# empty folder for redirect to /squirrel location ...
install -m 644 redirect.php $(DESTDIR)/usr/share/alternc-squirrelmail/index.php

View File

@ -1,22 +0,0 @@
<Location /squirrel>
ProxyPass http://squirrelmail.local/squirrel
ProxyPassReverse http://squirrelmail.local/squirrel
</Location>
Alias /squirrel /usr/share/squirrelmail
<Directory /usr/share/squirrelmail>
php_value open_basedir /usr/share/squirrelmail:/etc/squirrelmail/:/var/lib/squirrelmail/data/:/var/spool/squirrelmail/
php_admin_flag safe_mode off
Options Indexes FollowSymLinks
</Directory>
Alias /javascript /usr/share/javascript/
<Directory "/usr/share/javascript/">
Options FollowSymLinks MultiViews
Order allow,deny
Allow from all
</Directory>

View File

@ -1,23 +0,0 @@
<VirtualHost *:80>
ServerName squirrelmail.local
AssignUserId alternc-squirrelmail nogroup
# Due to the PROXY TRICK, We need squirrel to be available BOTH at / AND /squirrel ...
DocumentRoot /usr/share/squirrelmail/
Alias /squirrel /usr/share/squirrelmail
<Directory /usr/share/squirrelmail>
php_value open_basedir /usr/share/squirrelmail:/etc/squirrelmail/:/var/lib/squirrelmail/data/:/var/spool/squirrelmail/
php_admin_flag safe_mode off
Options Indexes FollowSymLinks
</Directory>
Alias /javascript /usr/share/javascript/
<Directory "/usr/share/javascript/">
Options FollowSymLinks MultiViews
Order allow,deny
Allow from all
</Directory>
</VirtualHost>

View File

@ -1,4 +0,0 @@
<?php
header("Location: /squirrel");

View File

@ -31,8 +31,7 @@ then
. /usr/lib/alternc/functions.sh
echo "Setting squirrelmail as default webmail & installing domaintype"
mysql_query "INSERT IGNORE INTO variable SET name='webmail_redirect', value='squirrel', comment='Set it to the name of your preferred webmail, /webmail will point to it (squirrel, rc...)';"
echo "Setting squirrelmail domaintype"
mysql_query "INSERT IGNORE INTO domaines_type (name ,description ,target ,entry ,compatibility ,enable ,only_dns ,need_dns ,advanced )VALUES ('squirrelmail','Squirrelmail Webmail access', 'NONE', '%SUB% IN A @@PUBLIC_IP@@', 'txt', 'ALL', '0', '0', '0');"
echo " Done"
@ -42,24 +41,6 @@ then
mysql_query "UPDATE sub_domaines SET web_action='DELETE' WHERE type='webmail' AND web_action='OK';"
echo " Done"
# echo "Adding squirrelmail.local in /etc/hosts for webmail vhost"
# if ! grep -q "127.0.0.1.*squirrelmail.local" /etc/hosts
# then
# echo "127.0.0.1 squirrelmail.local" >>/etc/hosts
# fi
fi
#if [ "$1" = "apache2" ]
#then
# echo "Installing Apache Proxy module for Squirrelmail ..."
# if ! [ -L /etc/apache2/mods-enabled/proxy.load ]
# then
# a2enmod proxy
# fi
# if ! [ -L /etc/apache2/mods-enabled/proxy_http.load ]
# then
# a2enmod proxy_http
# fi
# echo "Done"
#fi