forked from coordinape/coordinape
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
92 lines (85 loc) · 3.06 KB
/
docker-compose.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
version: '3.6'
services:
postgres: &postgres
profiles: ['dev']
image: postgres:13
restart: always
volumes:
- db_data:/var/lib/postgresql/data
ports:
- ${LOCAL_POSTGRES_PORT}:5432
environment:
POSTGRES_PASSWORD: ${LOCAL_POSTGRES_PASSWORD}
# Hasura
graphql-engine: &graphql_engine
profiles: ['dev']
image: hasura/graphql-engine:v2.1.1.cli-migrations-v3
volumes:
- ./hasura/migrations:/hasura-migrations
- ./hasura/metadata:/hasura-metadata
ports:
- ${LOCAL_HASURA_PORT:-8080}:8080
depends_on:
- postgres
restart: always
environment: &graphql_engine_environment
HASURA_GRAPHQL_DATABASE_URL: postgres://${LOCAL_POSTGRES_USER}:${LOCAL_POSTGRES_PASSWORD}@postgres/${LOCAL_POSTGRES_DATABASE}
HASURA_GRAPHQL_ENABLE_CONSOLE: 'true'
HASURA_GRAPHQL_DEV_MODE: 'true'
HASURA_GRAPHQL_ENABLED_LOG_TYPES: startup, http-log, webhook-log, websocket-log, query-log
HASURA_GRAPHQL_ADMIN_SECRET: ${HASURA_GRAPHQL_ADMIN_SECRET}
HASURA_EVENT_SECRET: ${HASURA_EVENT_SECRET}
# Linux (read: non macOS or Windows) users should
# `export DOCKER_GATEWAY_HOST=172.17.0.1` to interact with the host machine's ports
HASURA_API_BASE_URL: http://${DOCKER_GATEWAY_HOST:-host.docker.internal}:${LOCAL_WEB_PORT}/api/hasura
HASURA_GRAPHQL_AUTH_HOOK: http://${DOCKER_GATEWAY_HOST:-host.docker.internal}:${LOCAL_WEB_PORT}/api/hasura/auth
## HASURA_GRAPHQL_UNAUTHORIZED_ROLE: public
postgres-ci:
<<: *postgres
profiles: ['ci']
volumes:
- db_data_ci:/var/lib/postgresql/data
ports:
- ${CI_POSTGRES_PORT}:5432
graphql-engine-ci:
<<: *graphql_engine
profiles: ['ci']
ports:
- ${CI_HASURA_PORT}:8080
depends_on:
- postgres-ci
environment:
<<: *graphql_engine_environment
HASURA_GRAPHQL_DATABASE_URL: postgres://${LOCAL_POSTGRES_USER}:${LOCAL_POSTGRES_PASSWORD}@postgres-ci/${LOCAL_POSTGRES_DATABASE}
HASURA_API_BASE_URL: http://${DOCKER_GATEWAY_HOST:-host.docker.internal}:${CI_WEB_PORT}/api/hasura
HASURA_GRAPHQL_AUTH_HOOK: http://${DOCKER_GATEWAY_HOST:-host.docker.internal}:${CI_WEB_PORT}/api/hasura/auth
# for local s3 storage for images
localstack:
image: localstack/localstack:latest
restart: always
hostname: s3
networks:
default:
aliases:
- s3.localhost.localstack.cloud
- s3-website.localhost.localstack.cloud
- coordinape.s3.localhost.localstack.cloud
- coordinape.s3-website.localhost.localstack.cloud
environment:
- HOSTNAME_EXTERNAL=localstack
- AWS_DEFAULT_REGION=us-east-1
- EDGE_PORT=4566
- SERVICES=s3
- DATA_DIR=/tmp/localstack/data
ports:
- ${LOCAL_LOCALSTACK_PORT_RANGE:-4566-4583}:4566-4583
volumes:
- '${TEMPDIR:-/tmp/localstack}:/tmp/localstack'
- '/var/run/docker.sock:/var/run/docker.sock'
- ./docker/localstack/docker-entrypoint-initaws.d:/docker-entrypoint-initaws.d
networks:
default:
driver: bridge
volumes:
db_data: null
db_data_ci: null