fix(dev): 本地 API 默认端口改为 3100 避开 Windows 保留段
Hyper-V 常保留 2960-3059,3000 会 EACCES;ensure-port-free 与 Vite 代理从 apps/api/.env 读取 PORT
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { execSync } from 'node:child_process';
|
||||
import { resolveApiDevPort } from './dev-api-target.mjs';
|
||||
|
||||
const port = process.argv[2] ?? '3000';
|
||||
const port = process.argv[2] ?? resolveApiDevPort();
|
||||
|
||||
function killWindows(portNum) {
|
||||
let out = '';
|
||||
|
||||
Reference in New Issue
Block a user