Commits

Zhang Huangbin  committed 47381fa

* Remove 'old_passwords=' in my.cnf.
* Fixed: not create symbol link for Python programs on FreeBSD.
* Switch back to databases/mysql55-server on FreeBSD.
* Use new sample Dovecot config file for Dovecot-2.2 on FreeBSD.

  • Participants
  • Parent commits 8054632

Comments (0)

Files changed (4)

File iRedMail/functions/dovecot2.sh

 
     ECHO_DEBUG "Configure dovecot: ${DOVECOT_CONF}."
 
-    cp ${SAMPLE_DIR}/dovecot/dovecot2.conf ${DOVECOT_CONF}
+    # FreeBSD ships Dovecot-2.2
+    if [ X"${DISTRO}" == X'FREEBSD' ]; then
+        cp ${SAMPLE_DIR}/dovecot/dovecot22.conf ${DOVECOT_CONF}
+    else
+        cp ${SAMPLE_DIR}/dovecot/dovecot2.conf ${DOVECOT_CONF}
+    fi
     chmod 0664 ${DOVECOT_CONF}
 
     # Base directory.

File iRedMail/functions/mysql.sh

     else
         ECHO_DEBUG "Grant access privilege to ${MYSQL_ROOT_USER}@${LOCAL_ADDRESS} ..."
         mysql -u${MYSQL_ROOT_USER} <<EOF
--- Set root password
 USE mysql;
-UPDATE user SET Password = PASSWORD('${MYSQL_ROOT_PASSWD}') WHERE User = 'root';
 -- Allow access from MYSQL_GRANT_HOST with password
 GRANT ALL PRIVILEGES ON *.* TO '${MYSQL_ROOT_USER}'@'${MYSQL_GRANT_HOST}' IDENTIFIED BY '${MYSQL_ROOT_PASSWD}';
+GRANT ALL PRIVILEGES ON *.* TO '${MYSQL_ROOT_USER}'@'127.0.0.1' IDENTIFIED BY '${MYSQL_ROOT_PASSWD}';
 -- Allow GRANT privilege
 UPDATE user SET Grant_priv='Y' WHERE User='${MYSQL_ROOT_USER}' AND Host='${MYSQL_GRANT_HOST}';
+UPDATE user SET Grant_priv='Y' WHERE User='${MYSQL_ROOT_USER}' AND Host='127.0.0.1';
+-- Set root password
+UPDATE user SET Password = PASSWORD('${MYSQL_ROOT_PASSWD}') WHERE User = 'root';
 EOF
     fi
 

File iRedMail/functions/packages_freebsd.sh

     export PACKAGE_BUILDING='yes'
     export BATCH='yes'
     export WANT_OPENLDAP_VER='24'
-    export WANT_MYSQL_VER='56'
+    export WANT_MYSQL_VER='55'
     export WANT_PGSQL_VER='93'
     export WANT_BDB_VER='48'
     export WANT_APACHE_VER='22'
         fi
     done
 
+    # Create symbol link for Python.
+    ln -sf /usr/local/bin/python2.7 /usr/local/bin/python
+    ln -sf /usr/local/bin/python2.7 /usr/local/bin/python2
+    ln -sf /usr/local/bin/pydoc2.7  /usr/local/bin/pydoc
+    ln -sf /usr/local/bin/2to3-2.7 /usr/local/bin/2to3
+    ln -sf /usr/local/bin/python2.7-config /usr/local/bin/python-config
+
     # Log and print used time
     all_used_time="$(($(date +%s)-start_time))"
     ECHO_INFO "Total time of ports compiling: ${all_used_time} seconds, ~$((all_used_time/60)) minute(s)"

File iRedMail/samples/my.cnf

 #slow_query_log
 #slow_query_log_file = /var/log/mysql_slow.log
 
-# Default to using old password format for compatibility with mysql 3.x
-# clients (those using the mysqlclient10 compatibility package).
-old_passwords=1
-
 skip-external-locking
 #skip-bdb
 #skip-networking