-
-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Web UI base path #14787
Closed
Closed
Web UI base path #14787
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This will be removed upon every request. This is to allow easy reverse proxy filtering on the path level.
Adds a base path configuration option to the WebUI. WebApplication injects base path into content paths on initial configuration. Requires a restart to update. Internally, the path is stripped from the request to maintain the existing api/file structure. Requests without the path trigger a 303 redirect response. Closes qbittorrent#5693
Empty file was being returned when a trailing slash on the base path was missing
Fixed typo in prior commit
Removed unecessary VS file
Converted UTF-8 BOM to UTF-8 on appropriate files
kharenis
force-pushed
the
WebUI-BasePath
branch
from
April 14, 2021 12:29
4cca9e3
to
5b0d65c
Compare
Added space before closing /
Updated 'Base Path' to 'Base path' to match the other labels
Replace is now done against relative paths to improve maintainability.
Base path with now be written as a static path to avoid conflicts where the original request path ends with a /
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds a base path configuration for the WebUI.
This can be used for easy setup alongside reverse proxies that determine a backend based on the path.
(See #5693 Feature request)
When a request is received, it'll strip out the base path if found (in order to preserve the API/file structure) and insert the base path with a 303 redirect if not found.
The base path is now being injected into the client-side code to ensure everything gets routed correctly.
Changing the value requires the WebUI to be restarted, as when the value is changed there were redirection issues upon saving the new value, and I thought this would be the safest way of approaching it.