Last active
August 2, 2020 18:55
-
-
Save plmercereau/b8503c869ffa2b5d4e42dc9137b56ae1 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3.1' | |
services: | |
reverse-proxy: | |
image: traefik # The official Traefik docker image | |
command: --api --docker # Enables the web UI and tells Traefik to listen to docker | |
ports: | |
- "80:80" # The HTTP port | |
- "8080:8080" # The Web UI (enabled by --api) | |
volumes: | |
- /var/run/docker.sock:/var/run/docker.sock # So that Traefik can listen to the Docker events | |
postgres: | |
image: mdillon/postgis:11-alpine | |
restart: always | |
volumes: | |
- db_data:/var/lib/postgresql/data | |
authentication: | |
image: platyplus/authentication | |
restart: always | |
labels: | |
- "traefik.frontend.rule=Host:auth.${DOMAIN}" | |
- "traefik.port=8080" | |
depends_on: | |
- "postgres" | |
environment: | |
NODE_ENV: production | |
DATABASE_URL: postgres://postgres:@postgres:5432/postgres | |
AUTH_PRIVATE_KEY: "${PRIVATE_KEY}" | |
AUTH_PUBLIC_KEY: "${PUBLIC_KEY}" | |
graphql-engine: | |
image: hasura/graphql-engine:v1.0.0-alpha37 | |
labels: | |
- "traefik.frontend.rule=Host:graphql.${DOMAIN}" | |
- "traefik.port=8080" | |
depends_on: | |
- "postgres" | |
restart: always | |
environment: | |
HASURA_GRAPHQL_DATABASE_URL: postgres://postgres:@postgres:5432/postgres | |
HASURA_GRAPHQL_ENABLE_CONSOLE: "${HASURA_ENABLE_CONSOLE}" | |
HASURA_GRAPHQL_JWT_SECRET: '{"type":"RS256", "key":"${PUBLIC_KEY}"}' | |
HASURA_GRAPHQL_ACCESS_KEY: "${HASURA_ACCESS_KEY}" | |
volumes: | |
db_data: |
Yes I've used something from there, that way is working nice, and anyway it
will be the way I will use it, but adding the escaped public key didn't
work but this way is actually better for the way I need to implement it,
thanks a lot!
…On Fri, May 17, 2019 at 10:12 AM Pilou ***@***.***> wrote:
I think Hasura requires to escape the end of lines in the key variables
with "\n" instead. I am not sure this is the issue but I would give it a
try. I explain it in this repo
<https://github.com/platyplus/authentication-server>
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<https://gist.github.com/b8503c869ffa2b5d4e42dc9137b56ae1?email_source=notifications&email_token=AABMP3O5UJ6DGJFMZ4SFJC3PV3KPNA5CNFSM4HNSL4TKYY3PNVWWK3TUL52HS4DFVNDWS43UINXW23LFNZ2KUY3PNVWWK3TUL5UWJTQAFSHPM#gistcomment-2920182>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AABMP3LT3ZRXTK44R2LTUCTPV3KPNANCNFSM4HNSL4TA>
.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I think Hasura requires to escape the end of lines in the key variables with "\n" instead. I am not sure this is the issue but I would give it a try. I explain it in this repo. What I did to format the key in the right format: