]> Git — Sourcephile - gargantext.git/blob - devops/docker-postgres
+devops/docker-postgres
[gargantext.git] / devops / docker-postgres
1 set -eu
2 docker stop dbgarg || :
3 docker rm --volumes dbgarg || :
4 docker run --name dbgarg -e POSTGRES_USER=gargantua -e POSTGRES_DB=gargandbV5 -e POSTGRES_PASSWORD=C8kdcUrAQy66U -d postgres
5 sleep 3
6 export PGPASSWORD="$(grep DB_PASS gargantext.ini | \awk '{print $3}')"
7 docker run -e PGPASSWORD -i --rm --link dbgarg:postgres postgres psql -h postgres -U gargantua -d gargandbV5 < src/Gargantext/Database/Schema/schema.sql
8 #docker run -e PGPASSWORD -i --rm --link dbgarg:postgres postgres psql -h postgres -U gargantua -d gargandbV5 < gargantext.dump
9 #docker run -e PGPASSWORD -i --rm --link dbgarg:postgres postgres dropdb -h postgres -U gargantua gargandbV5