Commits

Zhang Huangbin committed ad18821

* Fix incorrect Apache DocumentRoot on Ubuntu 14.04.
* Disable unused Cluebringer policy, remove source '%internal_ips' in policy 'Default Outbound' by default.

Comments (0)

Files changed (4)

iRedMail/conf/apache_php

     export PHP_INI='/etc/php.ini'
 
 elif [ X"${DISTRO}" == X"DEBIAN" -o X"${DISTRO}" == X"UBUNTU" ]; then
+    # Daemon user.
+    export HTTPD_USER='www-data'
+    export HTTPD_GROUP='www-data'
+
     # Apache configuration files.
     export HTTPD_CONF_ROOT="/etc/apache2"
     export HTTPD_CONF="${HTTPD_CONF_ROOT}/apache2.conf"
+
+    # Web data.
+    export HTTPD_SERVERROOT='/usr/share/apache2'
+    export HTTPD_DOCUMENTROOT="/var/www"
+
     if [ X"${DISTRO_CODENAME}" == X'wheezy' \
         -o X"${DISTRO_CODENAME}" == X'precise' ]; then
         export HTTPD_CONF_DIR="${HTTPD_CONF_ROOT}/conf.d"
         export HTTPD_CONF_DIR="${HTTPD_CONF_ROOT}/conf-available"
         export HTTPD_SSL_CONF="${HTTPD_CONF_ROOT}/sites-available/default-ssl.conf"
         export HTTPD_MOD_CONF_SECURITY="${HTTPD_CONF_DIR}/security.conf"
+        export HTTPD_DOCUMENTROOT="/var/www/html"
     fi
 
-    # Web data.
-    export HTTPD_SERVERROOT='/usr/share/apache2'
-    export HTTPD_DOCUMENTROOT="/var/www"
-
-    # Daemon user.
-    export HTTPD_USER='www-data'
-    export HTTPD_GROUP='www-data'
-
     # Log file location.
     export HTTPD_LOG_ACCESSLOG='/var/log/apache2/access.log'
     export HTTPD_LOG_ERRORLOG='/var/log/apache2/error.log'

iRedMail/functions/awstats.sh

 <Directory ${AWSTATS_CGI_DIR}/>
     DirectoryIndex awstats.pl
     Options ExecCGI
-    #Order allow,deny
-    #Allow from all
+    Order allow,deny
+    Allow from all
     #Allow from ${LOCAL_ADDRESS}
 
     AuthName "Authorization Required"

iRedMail/functions/cluebringer.sh

 
 <Directory ${CLUEBRINGER_HTTPD_ROOT}/>
     DirectoryIndex index.php
-    #Order allow,deny
-    #Allow from all
+    Order allow,deny
+    Allow from all
     #Allow from ${CLUEBRINGER_BIND_HOST}
 
     AuthType basic

iRedMail/samples/cluebringer/extra.sql

 --  priority=10 Default Inbound
 --  priority=10 Default Outbound
 
+-- Disable unused policy: 'Default'.
+UPDATE policies SET Disabled=1 WHERE ID=1;
+
+-- Don't use '%internal_ips' in 'Default Outbound'.
+UPDATE policy_members SET Source='%internal_domains' WHERE PolicyID=2;
+
 -- Add new column: policy_group_members.Type.
 -- It's used to identify record type/kind in iRedAdmin-Pro, for easier
 -- management of white/blacklists.