部署脚本

This commit is contained in:
wanghai
2026-07-20 13:46:08 +08:00
parent ba4d74a23f
commit 5cc55f7f03
6 changed files with 541 additions and 162 deletions

View File

@@ -12,9 +12,9 @@ services:
container_name: ecshopx-dev
restart: unless-stopped
ports:
- "8080:8080" # Nginx (容器8080端口映射到主机8080端口)
- "8081:8081" # Nginx H5前端服务 (容器8081端口映射到主机8081端口)
- "8082:8082" # Nginx PC前端代理 (容器8082端口映射到主机8082端口)
- "${ADMIN_HOST_PORT:-8080}:8080" # Nginx 管理后台/API
- "${H5_HOST_PORT:-8081}:8081" # Nginx H5 前端服务
- "${PC_HOST_PORT:-8082}:8082" # Nginx PC 前端代理
volumes:
# 挂载目录
- ..:/data/httpd
@@ -63,6 +63,11 @@ services:
- NUXT_WAIT_INTERVAL=10
# SSR 走容器内网访问 API不影响管理后台
- NUXT_API_BASE=http://ecshopx-dev:8080/api/h5app
- NUXT_INTERNAL_API_BASE=http://ecshopx-dev:8080/api/h5app
# 浏览器侧请求使用外部可访问地址dev-setup.sh 会按安装配置传入
- NUXT_PUBLIC_API_BASE=${NUXT_PUBLIC_API_BASE:-http://localhost:8080/api/h5app}
# PC 装修预览允许接收的后台 origindev-setup.sh 会按管理后台地址传入
- NUXT_PUBLIC_DECORATION_ADMIN_ORIGINS=${NUXT_PUBLIC_DECORATION_ADMIN_ORIGINS:-http://localhost:8080}
networks:
- ecshopx-dev-network