File tree 3 files changed +28
-5
lines changed
3 files changed +28
-5
lines changed Original file line number Diff line number Diff line change 21
21
},
22
22
"DATABASE_CONF" : {
23
23
"DATABASE" : " postgresql" ,
24
- "POSTGRES_SERVER" : " localhost " ,
24
+ "POSTGRES_SERVER" : " fastapidb " ,
25
25
"POSTGRES_PORT" : " 5432" ,
26
- "POSTGRES_USER" : " " ,
27
- "POSTGRES_PASSWORD" : " " ,
26
+ "POSTGRES_USER" : " postgres " ,
27
+ "POSTGRES_PASSWORD" : " postgres " ,
28
28
"POSTGRES_DB" : " postgres" ,
29
29
"POSTGRES_ADAPTER" : " psycopg2"
30
30
}
Original file line number Diff line number Diff line change @@ -11,4 +11,5 @@ async-exit-stack
11
11
async-generator
12
12
async-exit-stack
13
13
async-generator
14
- uuid == 1.30
14
+ uuid == 1.30
15
+ sqlmodel
Original file line number Diff line number Diff line change @@ -7,4 +7,26 @@ services:
7
7
ports :
8
8
- " 8088:80"
9
9
volumes :
10
- - " /home/user/docker_data/:/var/data"
10
+ - " /home/user/docker_data/:/var/data"
11
+ networks :
12
+ - fastapinetwork
13
+
14
+ fastapidb :
15
+ image : postgres:13.4-alpine
16
+ container_name : db
17
+ volumes :
18
+ - postgres_data:/var/lib/postgresql/data/
19
+ environment :
20
+ - POSTGRES_USER=postgres
21
+ - POSTGRES_PASSWORD=postgres
22
+ # - POSTGRES_DB=scidatamanager
23
+ networks :
24
+ - fastapinetwork
25
+ ports :
26
+ - 5432:5432
27
+ networks :
28
+ fastapinetwork :
29
+ driver : bridge
30
+
31
+ volumes :
32
+ postgres_data:
You can’t perform that action at this time.
0 commit comments