From ba857e3859966e857c5a741825411575e17446de Mon Sep 17 00:00:00 2001 From: arekkas Date: Sat, 21 Jul 2018 16:59:03 +0200 Subject: [PATCH] docker: Introduce docker-compose file for testing Signed-off-by: arekkas --- docker-compose.yml | 52 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 docker-compose.yml diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 000000000..60a52cfe6 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,52 @@ +########################################################################### +####### FOR DEMONSTRATION PURPOSES ONLY ####### +########################################################################### +# # +# If you have not yet read the tutorial, do so now: # +# https://ory-am.gitbooks.io/hydra/content/tutorial.html # +# # +# This set up is only for demonstration purposes. The login # +# endpoint can only be used if you follow the steps in the tutorial. # +# # +########################################################################### + +version: '2' + +services: + + keto-migrate: + build: + context: . + dockerfile: Dockerfile + links: + - postgresd:postgresd + environment: + - LOG_LEVEL=debug + command: + migrate sql postgres://dbuser:secret@postgresd:5432/accesscontroldb?sslmode=disable + restart: on-failure + + keto: + build: + context: . + dockerfile: Dockerfile + links: + - postgresd:postgresd + ports: + - "4466:4466" + depends_on: + - keto-migrate + command: + serve + environment: + - LOG_LEVEL=debug + - PORT=4466 + - DATABASE_URL=postgres://dbuser:secret@postgresd:5432/accesscontroldb?sslmode=disable + restart: on-failure + + postgresd: + image: postgres:9.6 + environment: + - POSTGRES_USER=dbuser + - POSTGRES_PASSWORD=secret + - POSTGRES_DB=accesscontroldb