From 1f1df8e2735fc42266411ea40e9558b97253bab4 Mon Sep 17 00:00:00 2001 From: naiba Date: Tue, 26 May 2026 05:56:12 +0000 Subject: [PATCH] ci(e2e): bind Vite dev server to loopback Co-authored-by: naiba/CloudCode Co-authored-by: cloudcode --- playwright.config.ts | 2 +- vite.config.ts | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/playwright.config.ts b/playwright.config.ts index d69a023..17e226d 100644 --- a/playwright.config.ts +++ b/playwright.config.ts @@ -24,7 +24,7 @@ export default defineConfig({ webServer: process.env.E2E_SKIP_WEBSERVER ? undefined : { - command: "npm run dev", + command: "npm run dev -- --host 127.0.0.1", url: baseURL + "/dashboard/login", reuseExistingServer: !process.env.CI, timeout: 120_000, diff --git a/vite.config.ts b/vite.config.ts index 8d3179c..540d5b6 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -8,12 +8,12 @@ export default defineConfig({ server: { proxy: { "^/api/v1/ws/.*": { - target: "ws://localhost:8008", + target: "ws://127.0.0.1:8008", changeOrigin: true, ws: true, }, "/api": { - target: "http://localhost:8008", + target: "http://127.0.0.1:8008", changeOrigin: true, }, },