Commits

Zhang Huangbin committed 0a54a5a

Fixed: incorrect command to init PostgreSQL db.

  • Participants
  • Parent commits 8aac371

Comments (0)

Files changed (2)

iRedMail/conf/global

 
 export PROG_NAME='iRedMail'
 export PROG_NAME_LOWERCASE='iredmail'
-export PROG_VERSION='0.9.0-beta1'
+export PROG_VERSION='0.9.0-beta2'
 
 export DATE="$(/bin/date +%Y.%m.%d.%H.%M.%S)"
 

iRedMail/functions/postgresql.sh

 
     # Init db
     if [ X"${DISTRO}" == X'RHEL' ]; then
-        ${PGSQL_RC_SCRIPT} initdb &>/dev/null
+        if [ X"${DISTRO_VERSION}"  == X'6' ]; then
+            ${PGSQL_RC_SCRIPT} initdb &>/dev/null
+        else
+            postgresql-setup initdb
+        fi
     elif [ X"${DISTRO}" == X'FREEBSD' ]; then
         # FreeBSD: Start pgsql when system start up.
         # Warning: We must have 'postgresql_enable=YES' before start/stop pgsql daemon.