aboutsummaryrefslogtreecommitdiff
path: root/docker-compose.yml
blob: 5ec2862d1d126dd33b1082799dc3de197b85daa1 (plain) (blame)
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
version: "3"
services:
  nginx:
    image: nginx:mainline-alpine
    networks:
      backend:
        ipv4_address: 172.21.23.2
    ports:
      - "36200:80"
    volumes:
      - ./static:/var/www
      - ./nginx.conf:/etc/nginx/nginx.conf

  app:
    build: .
    image: dispatch-app:latest
    networks:
      backend:
        ipv4_address: 172.21.23.3
    working_dir: /app
    volumes:
      - ./app:/app
      - ./static:/var/www

  postgres:
    image: postgres:11-alpine
    networks:
      backend:
        ipv4_address: 172.21.23.4
    volumes:
      - db-data:/var/lib/postgresql/data

volumes:
  db-data:

networks:
  backend:
    driver: bridge
    ipam:
      driver: default
      config:
        - subnet: 172.21.23.0/24