[PR #2289] [MERGED] Support reverseproxy to dashboard with additional parts in path. #4545

Closed
opened 2026-05-05 14:44:08 -06:00 by gitea-mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/fatedier/frp/pull/2289
Author: @YK-Samgo
Created: 3/10/2021
Status: Merged
Merged: 3/19/2021
Merged by: @fatedier

Base: devHead: dev


📝 Commits (1)

📊 Changes

11 files changed (+15 additions, -13 deletions)

View changed files

📝 assets/frps/static/index.html (+1 -1)
📝 assets/frps/static/manifest.js (+1 -1)
📝 assets/frps/static/vendor.js (+1 -1)
📝 assets/frps/statik/statik.go (+3 -1)
📝 web/frps/src/components/Overview.vue (+1 -1)
📝 web/frps/src/components/ProxiesHttp.vue (+2 -2)
📝 web/frps/src/components/ProxiesHttps.vue (+2 -2)
📝 web/frps/src/components/ProxiesStcp.vue (+1 -1)
📝 web/frps/src/components/ProxiesTcp.vue (+1 -1)
📝 web/frps/src/components/ProxiesUdp.vue (+1 -1)
📝 web/frps/src/components/Traffic.vue (+1 -1)

📄 Description

/api/ -> ../api/   in vendor.js
Support reverseproxy to dashboard with addtional parts in path.

The dashboard may fail to open with url like this:
https://www.abc.com/frps/static/#/
Because vendor.js call /api/serverinfo as absolute path. In the example, https://www.abc.com/api/serverinfo
Replace /api/ in vendor.js with ../api/ so that it call the api with a workable path. In the example above, it actually calls https://www.abc.com/frps/api/serverinfo, which can be correctly reverse proxyed.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/fatedier/frp/pull/2289 **Author:** [@YK-Samgo](https://github.com/YK-Samgo) **Created:** 3/10/2021 **Status:** ✅ Merged **Merged:** 3/19/2021 **Merged by:** [@fatedier](https://github.com/fatedier) **Base:** `dev` ← **Head:** `dev` --- ### 📝 Commits (1) - [`4ade872`](https://github.com/fatedier/frp/commit/4ade87270f81c60027ca4144d1a047d66fa25a07) web/frps: ### 📊 Changes **11 files changed** (+15 additions, -13 deletions) <details> <summary>View changed files</summary> 📝 `assets/frps/static/index.html` (+1 -1) 📝 `assets/frps/static/manifest.js` (+1 -1) 📝 `assets/frps/static/vendor.js` (+1 -1) 📝 `assets/frps/statik/statik.go` (+3 -1) 📝 `web/frps/src/components/Overview.vue` (+1 -1) 📝 `web/frps/src/components/ProxiesHttp.vue` (+2 -2) 📝 `web/frps/src/components/ProxiesHttps.vue` (+2 -2) 📝 `web/frps/src/components/ProxiesStcp.vue` (+1 -1) 📝 `web/frps/src/components/ProxiesTcp.vue` (+1 -1) 📝 `web/frps/src/components/ProxiesUdp.vue` (+1 -1) 📝 `web/frps/src/components/Traffic.vue` (+1 -1) </details> ### 📄 Description /api/ -> ../api/ in vendor.js Support reverseproxy to dashboard with addtional parts in path. The dashboard may fail to open with url like this: https://www.abc.com/frps/static/#/ Because vendor.js call /api/serverinfo as absolute path. In the example, https://www.abc.com/api/serverinfo Replace /api/ in vendor.js with ../api/ so that it call the api with a workable path. In the example above, it actually calls https://www.abc.com/frps/api/serverinfo, which can be correctly reverse proxyed. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
gitea-mirror 2026-05-05 14:44:08 -06:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/frp#4545
No description provided.