From e6b729565699d5c1b4c1ca69a6a608b75f99b86f Mon Sep 17 00:00:00 2001 From: Daniel Fomin Date: Fri, 25 Jun 2021 18:56:45 +0200 Subject: [PATCH] Additions to the docker-compose setup docs --- docker_example/README.md | 14 +++++++++++++- docker_example/docker-compose.yml | 6 ++++-- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/docker_example/README.md b/docker_example/README.md index c0fbd402..4d1e31cd 100644 --- a/docker_example/README.md +++ b/docker_example/README.md @@ -10,14 +10,26 @@ edit env_local.list (found in the docker_example directory) and use your own val ## Run it on your local machine as a daemon +### Docker Run + cd into the docker_example directory in this repo and run the following. You only need to be in this directory because we used a relative path to the env_local.list file. `docker run -p 8885:3000 --name klaxon_local --env-file ./env_local.list --restart unless-stopped -d klaxon` +### Docker Compose + +to use docker-compose modify all values in docker.compose.yml to your liking and run the following command in the docker_example directory. + +`docker-compose up` + +Important values to change in docker-compose.yml: + +- db -> environment -> POSTGRES_PASSWORD +- app -> ports ## View the app Go to your browser and hit `127.0.0.1:8885` . - +## Alternatively use docker-compose diff --git a/docker_example/docker-compose.yml b/docker_example/docker-compose.yml index d45b65fd..17b96437 100644 --- a/docker_example/docker-compose.yml +++ b/docker_example/docker-compose.yml @@ -11,11 +11,13 @@ services: - ./db:/var/lib/postgresql app: links: - - db + - db depends_on: - db image: themarshallproject/klaxon env_file: - env_local.list ports: - - 3000:3000 + - change_me:3000 + # Example: + # - 8885:3000