本地主机消除502

This commit is contained in:
2025-09-21 14:25:01 +08:00
parent b7d9f16198
commit e5eb8d6174
38 changed files with 56 additions and 73 deletions

View File

@@ -2,7 +2,7 @@
const common_vendor = require("./vendor.js");
const envBaseUrl = typeof process !== "undefined" && process.env && (process.env.VITE_APP_API_BASE_URL || process.env.API_BASE_URL) || "";
const storageBaseUrl = typeof common_vendor.index !== "undefined" ? common_vendor.index.getStorageSync("API_BASE_URL") || "" : "";
const fallbackBaseUrl = "http://192.168.31.193:8080";
const fallbackBaseUrl = "http://127.0.0.1:8080";
const API_BASE_URL = (envBaseUrl || storageBaseUrl || fallbackBaseUrl).replace(/\/$/, "");
const candidateBases = [envBaseUrl, storageBaseUrl, fallbackBaseUrl, "http://127.0.0.1:8080", "http://localhost:8080"];
const API_BASE_URL_CANDIDATES = Array.from(new Set(candidateBases.filter(Boolean))).map((u) => String(u).replace(/\/$/, ""));

View File

@@ -7072,9 +7072,9 @@ function isConsoleWritable() {
return isWritable;
}
function initRuntimeSocketService() {
const hosts = "198.18.0.1,192.168.31.107,127.0.0.1";
const hosts = "198.18.0.1,192.168.31.192,127.0.0.1";
const port = "8090";
const id = "mp-weixin_nY_uy5";
const id = "mp-weixin_qYdvJf";
const lazy = typeof swan !== "undefined";
let restoreError = lazy ? () => {
} : initOnError();