-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
63 lines (58 loc) · 1.38 KB
/
docker-compose.yml
File metadata and controls
63 lines (58 loc) · 1.38 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
version: '3.8'
services:
# PostgreSQL Database
postgres:
image: postgres:15-alpine
container_name: roomiesync-postgres
restart: unless-stopped
environment:
POSTGRES_DB: roomiesync_db
POSTGRES_USER: roomiesync
POSTGRES_PASSWORD: password
ports:
- "5433:5432"
volumes:
- postgres_data:/var/lib/postgresql/data
- ./init-scripts:/docker-entrypoint-initdb.d
networks:
- roomiesync-network
# NestJS Application
api:
build: .
container_name: roomiesync-api
restart: unless-stopped
ports:
- "3001:3001"
environment:
- DB_HOST=postgres
- DB_PORT=5432
- DB_USERNAME=roomiesync
- DB_PASSWORD=password
- DB_NAME=roomiesync_db
- NODE_ENV=production
- JWT_SECRET=your-super-secret-jwt-key-change-this-in-production
- JWT_EXPIRES_IN=7d
depends_on:
- postgres
networks:
- roomiesync-network
volumes:
- .:/app
- /app/node_modules
# pgAdmin for database management (optional)
pgadmin:
image: dpage/pgadmin4:latest
container_name: roomiesync-pgadmin
restart: unless-stopped
environment:
PGADMIN_DEFAULT_EMAIL: admin@roomiesync.com
PGADMIN_DEFAULT_PASSWORD: admin123
ports:
- "5050:80"
networks:
- roomiesync-network
volumes:
postgres_data:
networks:
roomiesync-network:
driver: bridge