fix: 修改 MySQL 默认端口映射为 3307,避免与本地 MySQL 冲突
- 将 docker-compose.yml 中 MySQL 端口映射默认值改为 3307 - 更新 deploy.sh 中的示例配置 - 容器内部仍使用 3306,仅外部映射端口改为 3307 - 容器间通信不受影响(通过 Docker 网络)
This commit is contained in:
@@ -55,8 +55,8 @@ SPRING_PROFILES_ACTIVE=prod
|
|||||||
# 服务器端口(对外暴露的端口)
|
# 服务器端口(对外暴露的端口)
|
||||||
SERVER_PORT=80
|
SERVER_PORT=80
|
||||||
|
|
||||||
# MySQL 端口(可选,用于外部连接)
|
# MySQL 端口(可选,用于外部连接,默认 3307 避免与本地 MySQL 冲突)
|
||||||
MYSQL_PORT=3306
|
MYSQL_PORT=3307
|
||||||
|
|
||||||
# Polygon RPC
|
# Polygon RPC
|
||||||
POLYGON_RPC_URL=https://polygon-rpc.com
|
POLYGON_RPC_URL=https://polygon-rpc.com
|
||||||
|
|||||||
+1
-1
@@ -28,7 +28,7 @@ services:
|
|||||||
image: mysql:8.2
|
image: mysql:8.2
|
||||||
container_name: polymarket-bot-mysql
|
container_name: polymarket-bot-mysql
|
||||||
ports:
|
ports:
|
||||||
- "${MYSQL_PORT:-3306}:3306"
|
- "${MYSQL_PORT:-3307}:3306"
|
||||||
environment:
|
environment:
|
||||||
- MYSQL_ROOT_PASSWORD=${DB_PASSWORD:-rootpassword}
|
- MYSQL_ROOT_PASSWORD=${DB_PASSWORD:-rootpassword}
|
||||||
- MYSQL_DATABASE=polymarket_bot
|
- MYSQL_DATABASE=polymarket_bot
|
||||||
|
|||||||
Reference in New Issue
Block a user