SvelteKit跨域POST提交被拦截问题求助(已配置ORIGIN)
Linux+Nginx反向代理SvelteKit应用出现跨域问题,ORIGIN环境变量配置无效
我在Linux服务器上用Nginx做反向代理,将sub.domain.com的流量转发到本地3000端口的SvelteKit应用,通过systemd管理服务并配置了ORIGIN环境变量:
[Service] Environment=ORIGIN=https://sub.domain.com
我检查了请求头,Origin字段确实是正确的https://sub.domain.com,而且已经从Deno适配器切换到Node适配器,但跨域问题依然存在。
更新信息
请求相关信息如下:
GENERAL HEADERS Request URL: https://sub.domain.com/login?/login Remote Address: 我的IP REQUEST HEADERS Host: sub.domain.com Origin: https://sub.domain.com Referer: https://sub.domain.com/login
我完全搞不懂为什么会出现跨域问题,调整ORIGIN环境变量也没有任何效果,求各位帮忙解决。
内容的提问来源于stack exchange,提问作者z0l1
相关产品推荐
相关产品推荐

