view schema/README @ 156:4ade330e571e

refactor: Refactor Dockerfile to reflect changes Tighten the run commands to streamline container build Include actual demousers.
author Thomas Junk <thomas.junk@intevation.de>
date Tue, 03 Jul 2018 11:40:16 +0200
parents dad6cf39691e
children a422471db08a
line wrap: on
line source

Build Dockerfile with e.g.:
$ docker build -t gemma .

Get a running instance with e.g.:
$ docker run --name gemma -d -p 54321:5432 -v $PWD:/opt/gemma gemma

Run tests for RLS policies as database superuser (within container) with:
$ psql -d gemma -Xf tap_tests.sql

Create ER diagrams with e.g.:
Auxiliary tables:
$ postgresql_autodoc -p 54321 -h $dockerhost \
      -U gemma --password=gemma -t dot -l . -s 'gemma'
$ dot -Tpdf gemma.dot > gemma_auxiliary.pdf

Waterway related tables:
$ postgresql_autodoc -p 54321 -h $dockerhost \
      -U gemma --password=gemma -t dot -l . -s 'gemma_waterway'
$ dot -Tpdf gemma.dot > gemma_waterway.pdf

Fairway/bottleneck related tables:
$ postgresql_autodoc -p 54321 -h $dockerhost \
      -U gemma --password=gemma -t dot -l . -s 'gemma_fairway'
$ dot -Tpdf gemma.dot > gemma_fairway.pdf