migrate 3000

This commit is contained in:
ryan
2026-06-18 16:24:43 +08:00
parent 4ddda8e733
commit e889247387
11 changed files with 13 additions and 12 deletions
+1 -1
View File
@@ -2,7 +2,7 @@
WAVELET_FRONTEND_URL=http://localhost:3000
# 后端 URL
WAVELET_BACKEND_URL=http://localhost:8000
WAVELET_BACKEND_URL=http://localhost:3000
# Session Cookie
WAVELET_SESSION_COOKIE_NAME=wavelet_session_id
@@ -68,7 +68,7 @@ export const howToUseSections: PolicySection[] = [
<p className="font-semibold text-xs text-muted-foreground">方式一:Authorization Bearer 头</p>
<CodeBlock
code={`GET /api/v1/user/self HTTP/1.1
Host: localhost:8000
Host: localhost:3000
Authorization: Bearer at_628d022b7a95e26b...`}
language="http"
/>
@@ -77,7 +77,7 @@ Authorization: Bearer at_628d022b7a95e26b...`}
<p className="font-semibold text-xs text-muted-foreground">方式二:X-Access-Token 自定义头</p>
<CodeBlock
code={`GET /api/v1/user/self HTTP/1.1
Host: localhost:8000
Host: localhost:3000
X-Access-Token: at_628d022b7a95e26b...`}
language="http"
/>
+1 -1
View File
@@ -8,7 +8,7 @@
*/
export function getApiBaseUrl(): string {
if (typeof window === 'undefined') {
return process.env.WAVELET_BACKEND_URL || process.env.NEXT_PUBLIC_WAVELET_BACKEND_URL || 'http://localhost:8000';
return process.env.WAVELET_BACKEND_URL || process.env.NEXT_PUBLIC_WAVELET_BACKEND_URL || 'http://localhost:3000';
}
return process.env.NEXT_PUBLIC_WAVELET_BACKEND_URL || '';
}
+1 -1
View File
@@ -8,7 +8,7 @@ const nextConfig: NextConfig = {
},
...(isExport ? { output: 'export' } : {
async rewrites() {
const backendUrl = process.env.WAVELET_BACKEND_URL || 'http://localhost:8000';
const backendUrl = process.env.WAVELET_BACKEND_URL || 'http://localhost:3000';
return [
// 上传文件静态资源
{