view db_schema/setup-db.sh @ 749:cb841ed21405

Dockerfile: add comment where server is reachable.
author Tom Gottfried <tom@intevation.de>
date Wed, 28 Oct 2015 11:05:28 +0100
parents 17165e710631
children 0cf9387c8da2
line wrap: on
line source
#!/bin/sh
DIR=`dirname $0`

ROLE_NAME=lada
ROLE_PW=lada
DB_NAME=lada

psql --command "CREATE USER $ROLE_NAME PASSWORD '$ROLE_PW';"
createdb -E UTF-8 $DB_NAME
psql -d $DB_NAME -f $DIR/lada_schema.sql
psql -d $DB_NAME --command \
     "GRANT USAGE ON SCHEMA stammdaten, bund, land TO $ROLE_NAME;
      GRANT SELECT, INSERT, UPDATE, DELETE, REFERENCES
            ON ALL TABLES IN SCHEMA stammdaten, bund, land TO $ROLE_NAME;"
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)