瀏覽代碼

build(env): 更新开发和生产环境中的 API 和 URL 地址- 将 VITE_APP_BASE_API 和 VITE_APP_BASE_URL 从本地地址 (127.0.0.1) 修改为容器内部地址 (172.17.0.2)
-此修改适用于 both 开发环境 (.

fusu 1 月之前
父節點
當前提交
626d1b94d7
共有 2 個文件被更改,包括 4 次插入4 次删除
  1. 2 2
      web/.env.development
  2. 2 2
      web/.env.production

+ 2 - 2
web/.env.development

@@ -1,5 +1,5 @@
-VITE_APP_BASE_API=http://127.0.0.1:8000
-VITE_APP_BASE_URL=http://127.0.0.1:8000
+VITE_APP_BASE_API=http://172.17.0.2:8000
+VITE_APP_BASE_URL=http://172.17.0.2:8000
 
 # https://docs.antdv-pro.com/guide/server.html
 # The following api is requested when the request parameter includes customDev

+ 2 - 2
web/.env.production

@@ -1,4 +1,4 @@
-VITE_APP_BASE_API=http://127.0.0.1:8000
-VITE_APP_BASE_URL=http://127.0.0.1:8000
+VITE_APP_BASE_API=http://172.17.0.2:8000
+VITE_APP_BASE_URL=http://172.17.0.2:8000
 # The title of your application (string)
 VITE_GLOB_APP_TITLE="N-admin"