Commits

Zhang Huangbin committed fa2ca4a

Code cleanup.

  • Participants
  • Parent commits 54b5465

Comments (0)

Files changed (3)

File iRedMail/conf/global

 # Enabled backends.
 export ENABLE_BACKEND_OPENLDAP='YES'
 export ENABLE_BACKEND_MYSQL='YES'
-export ENABLE_BACKEND_PGSQL='NO'
+export ENABLE_BACKEND_PGSQL='YES'
 # OpenBSD built-in LDAP daemon
 export ENABLE_BACKEND_LDAPD='NO'
 
         fi
 
         export PKG_ARCH=".${ARCH}"
-        if [ X"${DISTRO_VERSION}" == X"6" -a X"${ARCH}" == X"i386" ]; then
+        if [ X"${ARCH}" == X"i386" ]; then
             export PKG_ARCH=''
         fi
 
-        # Enable PostgreSQL backend on RHEL/CentOS 6.
-        if [ X"${DISTRO_VERSION}" == X'6' ]; then
-            export ENABLE_BACKEND_PGSQL='YES'
-        fi
-
     elif [ -f /etc/lsb-release ]; then
         # Ubuntu
         export DISTRO='UBUNTU'
         export DISTRO_VERSION="$(grep 'DISTRIB_RELEASE' /etc/lsb-release | awk -F'=' '{print $2}')"
         export DISTRO_CODENAME="$(grep 'DISTRIB_CODENAME' /etc/lsb-release | awk -F'=' '{print $2}')"
 
-        # Support PGSQL backend on Ubuntu 11.10 and later releases
-        export ENABLE_BACKEND_PGSQL='YES'
-
         # Unsupported releases.
         #   - 8.04: hardy
         #   - 8.10: intrepid
             grep -i '^wheezy' /etc/debian_version &>/dev/null; then
             export DISTRO_VERSION='7'
             export DISTRO_CODENAME='wheezy'
-            export ENABLE_BACKEND_PGSQL='YES'
         else
             export UNSUPPORTED_RELEASE='YES'
         fi
     export SSL_FILE_DIR="/etc/ssl"
 
 elif [ X"${DISTRO}" == X"FREEBSD" ]; then
-    export ENABLE_BACKEND_PGSQL='YES'
-
     # System user: root.
     export SYS_ROOT_USER='root'
     export SYS_ROOT_GROUP='wheel'
     export LOGROTATE_DIR="/usr/local/etc/logrotate.d"
 
 elif [ X"${DISTRO}" == X'OPENBSD' ]; then
-    export ENABLE_BACKEND_PGSQL='YES'
     export ENABLE_BACKEND_LDAPD='YES'
 
     # System user: root.

File iRedMail/functions/packages.sh

             fi
             ALL_PKGS="${ALL_PKGS} mysql${PKG_ARCH}"
 
-            # For Awstats.
-            [ X"${USE_AWSTATS}" == X"YES" ] && ALL_PKGS="${ALL_PKGS} mod_auth_mysql${PKG_ARCH}"
-
         elif [ X"${DISTRO}" == X"DEBIAN" -o X"${DISTRO}" == X"UBUNTU" ]; then
             # MySQL server and client.
             if [ X"${USE_LOCAL_MYSQL_SERVER}" == X'YES' ]; then
     #
     if [ X"${USE_AWSTATS}" == X"YES" ]; then
         if [ X"${DISTRO}" == X"RHEL" ]; then
-            ALL_PKGS="${ALL_PKGS} awstats.noarch"
+            ALL_PKGS="${ALL_PKGS} awstats.noarch mod_auth_mysql${PKG_ARCH}"
         elif [ X"${DISTRO}" == X"DEBIAN" -o X"${DISTRO}" == X"UBUNTU" ]; then
             ALL_PKGS="${ALL_PKGS} awstats"
         elif [ X"${DISTRO}" == X'OPENBSD' ]; then

File iRedMail/pkgs/get_all.sh

     eval ${install_pkg} epel-release && rm ${YUM_REPOS_DIR}/tmp_epel.repo
     yum clean metadata
 
-    echo 'export status_create_yum_repo="DONE"' >> ${STATUS_FILE}
+    echo 'export status_create_repo_rhel="DONE"' >> ${STATUS_FILE}
 }
 
 check_new_iredmail()