优化Docker本地部署
This commit is contained in:
@@ -9,7 +9,7 @@ services:
|
||||
volumes:
|
||||
- mysql-data:/var/lib/mysql
|
||||
ports:
|
||||
- "3306:3306"
|
||||
- "${MYSQL_PORT:-3306}:3306"
|
||||
healthcheck:
|
||||
test: ["CMD", "mysqladmin", "ping", "-h", "localhost"]
|
||||
interval: 10s
|
||||
@@ -27,7 +27,7 @@ services:
|
||||
mysql:
|
||||
condition: service_healthy
|
||||
ports:
|
||||
- "8000:8000"
|
||||
- "${BACKEND_PORT:-8000}:8000"
|
||||
|
||||
frontend:
|
||||
build:
|
||||
@@ -35,7 +35,7 @@ services:
|
||||
depends_on:
|
||||
- backend
|
||||
ports:
|
||||
- "8080:80"
|
||||
- "${FRONTEND_PORT:-8080}:80"
|
||||
|
||||
volumes:
|
||||
mysql-data:
|
||||
|
||||
Reference in New Issue
Block a user