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

Dual http https #2120

Draft
wants to merge 2 commits into
base: master
from

Conversation

@TylerLubeck
Copy link
Contributor

commented Sep 26, 2019

This takes a stab at solving #1466. It would be beneficial for some work I'm involved in where we need to convert all our apps to https communication, and would like to avoid adding technologies (nginx in front of the app, running two separate application pools, etc).

It doesn't quite work yet, but I wanted to ask for an earlier look at methodology and implementation.

The idea is that there's a new flag --bind-no-ssl where, regardless of other configurations, ssl settings will not be applied. I chose to go this route to minimize compatibility problems.

Some examples:

  • gunicorn --bind-no-ssl 127.0.0.1:8001:
    Works the same as gunicorn --bind 127.0.0.1:8001

  • gunicorn --bind 127.0.0.1:8001 --bind-no-ssl 127.0.0.1:8002:
    Works the same as gunicorn --bind 127.0.0.1:8001 --bind 127.0.0.1:8002

  • gunicorn --certfile ./mycert --keyfile ./mykey --bind 127.0.0.1:8001 --bind-no-ssl 127.0.0.1:8002:
    Serves on https://127.0.0.1:8001 and http://127.0.0.1:8002

TylerLubeck added 2 commits Sep 26, 2019
The Tornado workers don't seem to be able to support this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.