docker-compose.yml 525 Bytes
Newer Older
Jon Yu's avatar
Jon Yu committed
1
2
3
4
version: '3'

services:
  app:
5
    build:
6
      context: ./src
7
8
      args:
          ENVIRONMENT: DEVELOPMENT
9
    env_file: ./src/.env
Jon Yu's avatar
Jon Yu committed
10
11
12
    ports:
      - 127.0.0.1:8000:8000
    volumes:
13
      - ./src:/usr/src/app
Jon Yu's avatar
Jon Yu committed
14
    entrypoint: ./docker-entrypoint.sh
15
    command: "python3 manage.py runserver 0.0.0.0:8000 --nostatic"
Jon Yu's avatar
Jon Yu committed
16
17
18
19
20
21
22
23
24
25
26
27
    depends_on:
      - db
  db:
    image: postgres:12-alpine
    env_file:
      - ./db/.env
    ports:
      - 5432:5432
    volumes:
      - postgres-data:/var/lib/pgsql/data
volumes:
  postgres-data: