[evolvis-commits] r16743: Cerate user in proper place↵

mirabilos at evolvis.org mirabilos at evolvis.org
Tue Mar 1 01:38:01 CET 2011


Author: mirabilos
Date: 2011-03-01 01:38:01 +0100 (Tue, 01 Mar 2011)
New Revision: 16743

Modified:
   trunk/gforge_base/evolvisforge-5.1/src/deb-specific/install-db.sh
   trunk/gforge_base/evolvisforge-5.1/src/plugins/forumml/db/forumml-init.sql
Log:
Cerate user in proper place


Modified: trunk/gforge_base/evolvisforge-5.1/src/deb-specific/install-db.sh
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/src/deb-specific/install-db.sh	2011-03-01 00:37:59 UTC (rev 16742)
+++ trunk/gforge_base/evolvisforge-5.1/src/deb-specific/install-db.sh	2011-03-01 00:38:01 UTC (rev 16743)
@@ -184,6 +184,24 @@
 	    rm -f $tmp1 $tmp2
 	    exit 1
 	fi
+	if su -s /bin/sh postgres -c "/usr/bin/psql template1" 1> $tmp1 2> $tmp2 <<-EOF
+SET LC_MESSAGES = 'C' ;
+CREATE USER list ;
+EOF
+	then
+	    rm -f $tmp1 $tmp2
+	else
+	    echo "Cannot create PostgreSQL user...  This shouldn't have happened."
+	    echo "Maybe a problem in your PostgreSQL configuration?"
+	    echo "Please report a bug to the Debian bug tracking system"
+	    echo "Please include the following output:"
+	    echo "CREATE USER's STDOUT:"
+	    cat $tmp1
+	    echo "CREATE USER's STDERR:"
+	    cat $tmp2
+	    rm -f $tmp1 $tmp2
+	    exit 1
+	fi
 	
         # Create the appropriate database
 	tmp1=$(mktemp /tmp/$pattern)

Modified: trunk/gforge_base/evolvisforge-5.1/src/plugins/forumml/db/forumml-init.sql
===================================================================
--- trunk/gforge_base/evolvisforge-5.1/src/plugins/forumml/db/forumml-init.sql	2011-03-01 00:37:59 UTC (rev 16742)
+++ trunk/gforge_base/evolvisforge-5.1/src/plugins/forumml/db/forumml-init.sql	2011-03-01 00:38:01 UTC (rev 16743)
@@ -1,4 +1,3 @@
-CREATE USER list;
 -- alter table plugin_forumml_message add column last_thread_update int unsigned not null default 0 after body;
 CREATE SEQUENCE plugin_forumml_pk_seq
     START WITH 1



More information about the evolvis-commits mailing list