-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
49 lines (48 loc) · 1.14 KB
/
Copy pathdocker-compose.yml
File metadata and controls
49 lines (48 loc) · 1.14 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
services:
db:
image: postgres:16.10-alpine3.22
environment:
POSTGRES_USER: myuser
POSTGRES_PASSWORD: mypassword
POSTGRES_DB: mydatabase
volumes:
- postgres:/var/lib/postgresql/data
ports:
- "5432:5432"
api:
build:
context: ./nari-note-backend
dockerfile: Dockerfile
command: dotnet watch run --urls http://0.0.0.0:5243
depends_on:
- db
environment:
ConnectionStrings__DefaultConnection: "Host=db;Port=5432;Database=mydatabase;Username=myuser;Password=mypassword"
ports:
- "5243:5243"
volumes:
- ./nari-note-backend:/app:cached
- nuget:/root/.nuget/packages:cached
tty: true
stdin_open: true
web:
build:
context: ./nari-note-frontend
dockerfile: Dockerfile
command: sh -c "npm install && npm run dev"
depends_on:
- api
environment:
- NODE_ENV=development
- API_URL=http://api:5243
ports:
- "3000:3000"
volumes:
- ./nari-note-frontend:/app:cached
- node_modules:/app/node_modules:cached
tty: true
stdin_open: true
volumes:
postgres:
nuget:
node_modules: