-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yaml
More file actions
57 lines (54 loc) · 1.54 KB
/
docker-compose.yaml
File metadata and controls
57 lines (54 loc) · 1.54 KB
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
name: rc-select-backend-new
x-server: &base_server_setup
build:
context: ./
# Used for python debugging.
stdin_open: true
tty: true
environment: &base_server_environments
DEBUG: ${DEBUG:-true}
APP_ENVIRONMENT: ${APP_ENVIRONMENT:-DEV}
DJANGO_SECRET_KEY: ${DJANGO_SECRET_KEY:?error}
# Domain configs
APP_DOMAIN: ${APP_DOMAIN:-http://localhost:8000}
FRONTEND_DOMAIN: ${FRONTEND_DOMAIN:-http://localhost:3000} # NOTE: Not used right now
SESSION_COOKIE_DOMAIN: ${SESSION_COOKIE_DOMAIN:-localhost}
CSRF_COOKIE_DOMAIN: ${CSRF_COOKIE_DOMAIN:-localhost}
# Postgres
POSTGRES_DB: ${POSTGRES_DB:-rc-select}
POSTGRES_USER: ${POSTGRES_USER:-postgres}
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-postgres}
POSTGRES_HOST: ${POSTGRES_HOST:-db}
POSTGRES_PORT: ${POSTGRES_PORT:-5432}
env_file:
- path: .env
required: false
extra_hosts:
- "host.docker.internal:host-gateway"
volumes:
- ./:/code/
- ipython_data_local:/root/.ipython/profile_default # persist ipython data, including ipython history
depends_on:
- db
services:
db:
image: postgres:17
environment:
POSTGRES_DB: rc-select
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
volumes:
- postgres_data17:/var/lib/postgresql/data
web:
<<: *base_server_setup
command: ["/code/misc/dev/run_web.sh"]
environment:
<<: *base_server_environments
APP_TYPE: "WEB"
ports:
- 127.0.0.1:8000:8000
depends_on:
- db
volumes:
postgres_data17:
ipython_data_local: