forked from python/pythondotorg
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
29 lines (27 loc) · 765 Bytes
/
docker-compose.yml
File metadata and controls
29 lines (27 loc) · 765 Bytes
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
version: "3.9"
services:
postgres:
image: postgres:10-bullseye
ports:
- "5433:5432"
environment:
POSTGRES_USER: pythondotorg
POSTGRES_PASSWORD: pythondotorg
POSTGRES_DB: pythondotorg
POSTGRES_HOST_AUTH_METHOD: trust # never do this in production!
healthcheck:
test: ["CMD", "pg_isready", "-U", "pythondotorg", "-d", "pythondotorg"]
interval: 1s
web:
build: .
command: python manage.py runserver 0.0.0.0:8000
volumes:
- .:/code
ports:
- "8000:8000"
environment:
DATABASE_URL: postgresql://pythondotorg:pythondotorg@postgres:5432/pythondotorg
DJANGO_SETTINGS_MODULE: pydotorg.settings.local
depends_on:
postgres:
condition: service_healthy