clouddreamai-cicd-setup 1.5.34 → 1.5.35

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "clouddreamai-cicd-setup",
3
- "version": "1.5.34",
3
+ "version": "1.5.35",
4
4
  "description": "CloudDreamAI GitLab CI/CD 自动配置工具 - 支持 NestJS/Vue/React 项目的一键 CI/CD 配置",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -7,6 +7,8 @@ services:
7
7
  env_file:
8
8
  - .env
9
9
  restart: unless-stopped
10
+ extra_hosts:
11
+ - "host.docker.internal:host-gateway"
10
12
  networks:
11
13
  - app-network
12
14
 
@@ -438,6 +438,13 @@ fi
438
438
  echo "生成环境变量文件..."
439
439
  bash ci/generate-env.sh $ENV_TYPE
440
440
 
441
+ # 将 .env 中的本地地址替换为 host.docker.internal(容器内访问宿主机)
442
+ if [ -f ".env" ]; then
443
+ sed -i 's/=localhost$/=host.docker.internal/g' .env
444
+ sed -i 's/=127\.0\.0\.1$/=host.docker.internal/g' .env
445
+ echo "✓ 已将本地地址转换为容器可访问的地址"
446
+ fi
447
+
441
448
  # 创建数据库(如果启用)
442
449
  if [ "$DB_ENABLED" = "true" ]; then
443
450
  echo "检查数据库配置..."