summaryrefslogtreecommitdiffstats
path: root/sca-cpp/trunk/hosting/server/start
diff options
context:
space:
mode:
Diffstat (limited to 'sca-cpp/trunk/hosting/server/start')
-rwxr-xr-xsca-cpp/trunk/hosting/server/start16
1 files changed, 13 insertions, 3 deletions
diff --git a/sca-cpp/trunk/hosting/server/start b/sca-cpp/trunk/hosting/server/start
index d4443cb250..959863472b 100755
--- a/sca-cpp/trunk/hosting/server/start
+++ b/sca-cpp/trunk/hosting/server/start
@@ -22,7 +22,6 @@
# 127.0.0.1 www.example.com
here=`echo "import os; print os.path.realpath('$0')" | python`; here=`dirname $here`
-host=`hostname`
# Configure and start logging
if [ -x ../../components/log/scribe-cat ]; then
@@ -36,6 +35,17 @@ fi
../../components/cache/memcached-start tmp 11211
../../components/cache/memcached-start tmp 11212
+# Configure database
+../../components/sqldb/pgsql-conf tmp
+
+# Start database
+../../components/sqldb/pgsql-start tmp
+
+# Load database tables
+./drop-tables 1>/dev/null 2>/dev/null
+./create-tables >/dev/null
+./load-tables >/dev/null
+
# Clear document cache
rm -rf tmp/cache
@@ -55,8 +65,8 @@ if [ -x ../../components/log/scribe-cat ]; then
cat >tmp/conf/log.conf <<EOF
# Generated by: start $*
LogLevel notice
-ErrorLog "|$here/../../components/log/scribe-cat $host server"
-CustomLog "|$here/../../components/log/scribe-cat $host server" combined
+ErrorLog "|$here/../../components/log/scribe-cat localhost server"
+CustomLog "|$here/../../components/log/scribe-cat localhost server" combined
EOF