Skip to content

Commit 12eea8d

Browse files
feat: add docker compose files and initial database schema
Add docker-compose configurations for PostgreSQL and Minio services Include initial database migration script for EF Core with Users and BankAccounts tables
1 parent 983dee7 commit 12eea8d

File tree

4 files changed

+37
-2
lines changed

4 files changed

+37
-2
lines changed
File renamed without changes.

docker-composer-minio.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# docker-compose.yml
2+
version: '3.8'
3+
4+
services:
5+
minio:
6+
image: minio/minio
7+
container_name: minio-server
8+
ports:
9+
- "9000:9000"
10+
- "9001:9001"
11+
environment:
12+
MINIO_ROOT_USER: minioadmin
13+
MINIO_ROOT_PASSWORD: minioadmin123 # 👈 Đã đủ 12 ký tự
14+
volumes:
15+
- ./minio-data:/data
16+
command: server /data --console-address ":9001"
17+
restart: unless-stopped

docker-composer-pgsql.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
version: '3.9'
2+
3+
services:
4+
postgres:
5+
image: postgres:16
6+
container_name: postgres_db
7+
restart: always
8+
environment:
9+
POSTGRES_USER: postgres
10+
POSTGRES_PASSWORD: 1234
11+
POSTGRES_DB: chatdb
12+
ports:
13+
- "5432:5432"
14+
volumes:
15+
- postgres_data:/var/lib/postgresql/data
16+
17+
volumes:
18+
postgres_data:

readme.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@ http://localhost:5232/swagger/index.html
44

55
dotnet ef migrations add InitDb
66
dotnet ef database update
7-
8-
dotnet ef migrations script -o migrate.sql
7+
```export schema=chatdb
8+
dotnet ef migrations script -o Common/Schenma/migrate.sql
99

0 commit comments

Comments
 (0)