Skip to content
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

Reverse-proxying #1

Open
makew0rld opened this issue Jul 11, 2020 · 4 comments
Open

Reverse-proxying #1

makew0rld opened this issue Jul 11, 2020 · 4 comments
Labels
enhancement New feature or request

Comments

@makew0rld
Copy link

Feature request.

Gig looks great, nice work! I was wondering if reverse-proxying is on your roadmap, so all requests under a certain route or whatever is sent to a different Gemini server.

@pitr
Copy link
Owner

pitr commented Jul 13, 2020

this can be implemented using Context.Stream() or Context.Response() (which implements io.Writer interface), and using match-all routes, eg. g.Handle("/proxy/*",..). But a builtin middleware would be nicer if it would be contributed :)

@pitr pitr added the enhancement New feature or request label Jul 13, 2020
@makew0rld
Copy link
Author

As Michael noted in this comment this would break client certificates, but there might be other solutions like SNI proxies. Thanks for the info though.

@pitr
Copy link
Owner

pitr commented Jul 13, 2020

I thought you meant more of an tls-terminating proxy where server makes request on behalf of client, similar to how if I had an https proxy, it would make a separate connection to another https resource and pass response back to client

@makew0rld
Copy link
Author

Yes, that is what I was thinking originally. I only brought up SNI proxies because Michael did, and I think it's an interesting solution. The end result in most cases would be the same, better even, because client certs would remain intact.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants