-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
45 lines (35 loc) · 1.05 KB
/
docker-compose.yml
File metadata and controls
45 lines (35 loc) · 1.05 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
services:
postgres:
image: postgres:18.2 # latest
container_name: postgres_cryptowrap
environment:
POSTGRES_USER: ${DB_USER}
# ideally use docker compose secrets for this
POSTGRES_PASSWORD: ${DB_PASS}
POSTGRES_DB: ${DB_NAME}
ports: # expose with 5432 by default
- "127.0.0.1:5432:5432" # localhost only
volumes:
- postgres_data:/var/lib/postgresql
# restart: unless-stopped #always/no
restart: no
# networks: # it actually isolates container from outside network (e.g. ports : local forward won't work)
# - db_network # Both services share this network
# add redis container for stateless rate-limiting
main-cv:
image: gcr.io/distroless/cc-debian13
volumes:
- ./app/:/app
ports:
- "127.0.0.1:8080:8080"
working_dir: "/app"
command: [
"./release-cw"
]
restart: unless-stopped
volumes:
postgres_data:
# networks:
# db_network: # Creates an isolated network for the services
# driver: bridge
# ->./_*~^%$#@!&()+=?|":;<{}''"