-
Notifications
You must be signed in to change notification settings - Fork 3
/
docker-compose.yml
61 lines (56 loc) · 1.84 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
version: '3.7'
services:
proxy:
image: traefik:v2.3
command: --api.insecure=true --providers.docker
ports:
- "6969:80"
- "6970:8080"
volumes:
- /var/run/docker.sock:/var/run/docker.sock
parse-server:
build: ./server
restart: always
container_name: parse-server
env_file: .env
environment:
- APP_DATABASE_URI=mongodb://db:27017/${DB_NAME} # postgres://${DB_USER}:${DB_PASS}@db:5432/${DB_NAME}
depends_on:
- db
labels:
- "traefik.enable=true"
- "traefik.http.routers.api.rule=Host(`localhost`)" # example with ngrok - "traefik.http.routers.api.rule=Host(`localhost`) || HostRegexp(`{[a-z0-9]*}.ngrok.io"
volumes:
- ./server/cloud:/parse/cloud
# Regular MongoDB
db:
image: mongo:latest
restart: always
volumes:
- ./appdata/mongo:/data/db
labels:
- "traefik.enable=false"
# Postgis (PostgreSQL) - https://github.com/kartoza/docker-postgis
# db:
# image: kartoza/postgis:13.0
# restart: always
# environment:
# # If you need to create multiple database you can add coma separated databases eg gis,data
# - POSTGRES_DB=${DB_NAME}
# - POSTGRES_USER=${DB_USER}
# - POSTGRES_PASS=${DB_PASS}
# # - ALLOW_IP_RANGE=0.0.0.0/0
# # Add extensions you need to be enabled by default in the DB. Default are the five specified below
# - POSTGRES_MULTIPLE_EXTENSIONS=postgis,hstore,postgis_topology,postgis_raster,pgrouting
# volumes:
# - ./appdata/postgis:/var/lib/postgresql
# labels:
# - "traefik.enable=false"
# Percona Server MongoDB - https://hub.docker.com/r/percona/percona-server-mongodb
# db:
# image: percona/percona-server-mongodb:latest
# restart: always
# volumes:
# - ./appdata/percona-mongo:/data/db
# labels:
# - "traefik.enable=false"