Skip to content

[FEATURE] bind webhook server to unix socket? #3978

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

Closed
racinette opened this issue Nov 22, 2023 · 0 comments · Fixed by #3986
Closed

[FEATURE] bind webhook server to unix socket? #3978

racinette opened this issue Nov 22, 2023 · 0 comments · Fixed by #3986
Assignees

Comments

@racinette
Copy link

racinette commented Nov 22, 2023

What kind of feature are you missing? Where do you notice a shortcoming of PTB?

The usual thing to do with python web servers is to put them behind a reverse proxy, such as NGINX. And the usual thing to do to a server behind NGINX is to run it locally bound to a unix socket. However, there seems to be no way to do just that currently in PTB, as far as I can see in the webhookhandler.py file?

Describe the solution you'd like

I think I'd be nice to have an additional parameter in the WebhookServer constructor, such as unix_socket, which would bind the server to the specified unix socket instead of the host-port pair.

Describe alternatives you've considered

No response

Additional context

Here is the docs confirming, that currently you'd use NGINX only with a regular localhost connection.

@Poolitzer Poolitzer self-assigned this Nov 22, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Dec 22, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants