-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
81 lines (75 loc) · 1.84 KB
/
docker-compose.yml
File metadata and controls
81 lines (75 loc) · 1.84 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
version: '3'
services:
# front:
# container_name: "node_press_front_${NODE_ENV}"
# image: "node_press_front_${NODE_ENV}"
# depends_on:
# - postgres
# environment:
# - NODE_ENV:${NODE_ENV}
# build:
# context: ./frontend
# target: "${NODE_ENV}"
# dockerfile: Dockerfile
# entrypoint: ["npm", "run", "start:${NODE_ENV}"]
# env_file:
# - .env
# ports:
# - ${BACKEND_PORT}:3000
# networks:
# - backend
# volumes:
# - ./backend:/usr/src/app
# - /usr/src/app/node_modules
# restart: unless-stopped
# api:
# container_name: "node_press_${NODE_ENV}"
# image: "node_press_${NODE_ENV}"
# depends_on:
# - postgres
# environment:
# - NODE_ENV:${NODE_ENV}
# build:
# context: ./backend
# target: "${NODE_ENV}"
# dockerfile: Dockerfile
# entrypoint: ["npm", "run", "start:${NODE_ENV}"]
# env_file:
# - .env
# ports:
# - ${BACKEND_PORT}:3000
# networks:
# - backend
# volumes:
# - ./backend:/usr/src/app
# - /usr/src/app/node_modules
# restart: unless-stopped
postgres:
container_name: "node_press_postgres"
image: postgres:alpine
networks:
- backend
environment:
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD}
POSTGRES_USER: ${POSTGRES_USER}
POSTGRES_DB: "${POSTGRES_DB_NAME}"
PG_DATA: /var/lib/postgresql/data
ports:
- ${POSTGRES_DB_PORT}:5432
volumes:
- postgres:/var/lib/postgresql/data
pgweb:
restart: always
image: sosedoff/pgweb
ports:
- "8082:8081"
networks:
- backend
environment:
- DATABASE_URL=postgres://${POSTGRES_USER}:${POSTGRES_PASSWORD}@postgres:5432/${POSTGRES_DB_NAME}?sslmode=disable
depends_on:
- postgres
networks:
backend:
volumes:
postgres: