Skip to content

Commit 82b167f

Browse files
committed
feat: 更新 Vercel 配置,添加 .well-known 路径的重写规则和 CORS 头部
1 parent 8c20bdc commit 82b167f

File tree

1 file changed

+21
-8
lines changed

1 file changed

+21
-8
lines changed

vercel.json

Lines changed: 21 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,22 @@
11
{
2-
"rewrites": [
3-
{ "source": "/:match*", "destination": "/" },
4-
{
5-
"source": "/scratch/:path*",
6-
"destination": "/scratch/:path*"
7-
}
8-
]
9-
}
2+
"rewrites": [
3+
{
4+
"source": "/.well-known/webfinger",
5+
"destination": "${VITE_APP_BASE_API}/.well-known/webfinger"
6+
},
7+
{
8+
"source": "/.well-known/nodeinfo",
9+
"destination": "${VITE_APP_BASE_API}/.well-known/nodeinfo"
10+
},
11+
{
12+
"source": "/.well-known/host-meta",
13+
"destination": "${VITE_APP_BASE_API}/.well-known/host-meta"
14+
}
15+
],
16+
"headers": [
17+
{
18+
"source": "/.well-known/webfinger",
19+
"headers": [{ "key": "Access-Control-Allow-Origin", "value": "*" }]
20+
}
21+
]
22+
}

0 commit comments

Comments
 (0)