-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompose.yaml
More file actions
60 lines (60 loc) · 1.31 KB
/
compose.yaml
File metadata and controls
60 lines (60 loc) · 1.31 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
version: '3.8'
services:
postgres:
image: postgres:16.1-alpine
restart: on-failure
ports:
- '5432:5432'
environment:
POSTGRES_DB: '${DB_DATABASE}'
POSTGRES_USER: '${DB_USERNAME}'
POSTGRES_PASSWORD: '${DB_PASSWORD:-secret}'
volumes:
- postgres-data:/var/lib/postgresql/data
networks:
- app-network
app:
build:
context: .
dockerfile: Dockerfile
container_name: server
restart: unless-stopped
tty: true
profiles:
- dev-integration
environment:
APP_ENV: '${APP_ENV:-prod}'
APP_DEBUG: '${APP_DEBUG:-false}'
APP_URL: '${APP_URL:-http://localhost:9000}'
DB_DATABASE: '${DB_DATABASE}'
DB_USERNAME: '${DB_USERNAME}'
DB_PASSWORD: '${DB_PASSWORD:-secret}'
DB_HOST: '${DB_HOST:-postgres}'
ports:
- 9000:9000
networks:
- app-network
depends_on:
- postgres
swagger-ui:
image: swaggerapi/swagger-ui:latest
container_name: swagger-ui
restart: on-failure
profiles:
- dev-integration
ports:
- 9010:8080
environment:
SWAGGER_JSON: /docs/api-spec.yaml
depends_on:
- app
volumes:
- './docs:/docs'
networks:
- app-network
volumes:
postgres-data:
driver: local
networks:
app-network:
driver: bridge