-
Notifications
You must be signed in to change notification settings - Fork 889
fix: allow ports in wildcard url configuration #11657
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
Merged
Merged
Conversation
This file contains hidden or 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 stack of pull requests is managed by Graphite. Learn more about stacking. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs tests for actual serving too, and the frontend should be checked to ensure it functions with this
@deansheather I checked the frontend. I'll add some tests. |
This just forwards the port to the ui that generates urls. Our existing parsing + regex already supported ports for subdomain app requests.
a673da8
to
ed4410c
Compare
deansheather
approved these changes
Jan 18, 2024
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
This just forwards the port to the ui that generates urls.
Our existing parsing + regex already supported ports for
subdomain app requests.
Closes #8189
Tested with subdomain apps and port forwarding.
Remanent of the past
We have this old assumption that apphost and accessurl are on the same port.
coder/coderd/workspaceapps.go
Lines 35 to 38 in 2b4ea6d
This might now not be the case. For backwards compatibility, we have to keep this here, but it could be a problem if the access url has a port, and the wildcard domain does not.
Workspace proxies?
Workspace proxies do not have this "port inheritance" thing going on. I think the port inheritance is a mistake, but for backwards compatibility, it has to be kept on the primary.