voterunner

quick and dirty votes and discussions
git clone https://git.ce9e.org/voterunner.git

commit
aafb60479a78b2889cbe45a4431d1e099f46e02b
parent
7ddbdd58cb56cb9192495447c8564755ee14fca6
Author
Tobias Bengfort <tobias.bengfort@liqd.de>
Date
2016-09-15 13:46
make initialize_db.sh work on debian

Diffstat

M bin/initialize_db.sh 13 +++++++------

1 files changed, 7 insertions, 6 deletions


diff --git a/bin/initialize_db.sh b/bin/initialize_db.sh

@@ -1,10 +1,11 @@
    1     1 #!/bin/sh
    2     2 
    3     3 cd "$(dirname "$0")/.."
    4    -1 mkdir -p data/postgres
    5    -1 if test ! -d  data/postgres/base; then
    6    -1 	pg_ctl initdb -D data/postgres
    7    -1 	pg_ctl start -w -D data/postgres -o "-h localhost"
    8    -1 	createdb voterunner
    9    -1 	pg_ctl stop -D data/postgres
   -1     4 DB_DIR="$(pwd)/data/postgres"
   -1     5 mkdir -p $DB_DIR
   -1     6 if test ! -d "$DB_DIR/base"; then
   -1     7 	pg_ctl initdb -D "$DB_DIR"
   -1     8 	pg_ctl start -w -D "$DB_DIR" -o "-h localhost" -o "-k '$DB_DIR'"
   -1     9 	createdb -h "$DB_DIR" voterunner
   -1    10 	pg_ctl stop -D "$DB_DIR"
   10    11 fi