File tree 2 files changed +20
-2
lines changed 2 files changed +20
-2
lines changed Original file line number Diff line number Diff line change @@ -15,9 +15,10 @@ ADMINER_PORT=8081
15
15
# Prefect
16
16
PREFECT_TAG = 2.13.2-python3.10
17
17
PREFECT_PORT = 4200
18
+ PREFECT_DB_PORT = 5433
18
19
PREFECT_UI_URL = http://127.0.0.1:4200/api
19
20
PREFECT_SERVER_API_URL = http://127.0.0.1:4200/api
20
- PREFECT_API_DATABASE_CONNECTION_URL = postgresql+asyncpg://${ DB_USER } :${ DB_PASSWORD } @postgres:5432/${ DB_NAME }
21
+ PREFECT_API_DATABASE_CONNECTION_URL = postgresql+asyncpg://${ DB_USER } :${ DB_PASSWORD } @prefect- postgres:5432/prefect
21
22
PREFECT_API_URL = http://prefect-server:4200/api
22
23
23
24
# MLFlow
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ services:
44
44
PREFECT_SERVER_API_HOST : 0.0.0.0
45
45
PREFECT_API_DATABASE_CONNECTION_URL : $PREFECT_API_DATABASE_CONNECTION_URL
46
46
depends_on :
47
- - postgres
47
+ - prefect- postgres
48
48
ports :
49
49
- ${PREFECT_PORT}:4200
50
50
volumes :
@@ -101,6 +101,22 @@ services:
101
101
[[ ! -z "`/usr/bin/mc ls s3 | grep challenge`" ]] || /usr/bin/mc mb s3/prefect-flows; /usr/bin/mc policy download s3/prefect-flows;
102
102
[[ ! -z "`/usr/bin/mc ls s3 | grep challenge`" ]] || /usr/bin/mc mb s3/data; /usr/bin/mc policy download s3/data; exit 0; '
103
103
104
+ prefect-postgres :
105
+ image : postgres:${POSTGRES_TAG}
106
+ container_name : ${PROJECT_NAME}-prefect-postgres
107
+ hostname : prefect-postgres
108
+ restart : unless-stopped
109
+ stop_grace_period : 10s
110
+ env_file : .env
111
+ environment :
112
+ POSTGRES_PASSWORD : $DB_PASSWORD
113
+ POSTGRES_DB : prefect
114
+ POSTGRES_USER : $DB_USER
115
+ ports :
116
+ - ${PREFECT_DB_PORT}:5432
117
+ volumes :
118
+ - prefect-postgres-data:/var/lib/postgresql/data
119
+
104
120
postgres :
105
121
image : postgres:${POSTGRES_TAG}
106
122
container_name : ${PROJECT_NAME}-postgres
@@ -149,6 +165,7 @@ networks:
149
165
volumes :
150
166
prefect-data : {}
151
167
postgres-data : {}
168
+ prefect-postgres-data : {}
152
169
minio-data : {}
153
170
portainer-data : {}
154
171
You can’t perform that action at this time.
0 commit comments