If you pass Rocket an SSL certificate, it will only listen on that 
interface. If you want it to listen on multiple interfaces, you have to use 
the "--interfaces" argument instead. Something like:

python web2py.py -a adminpassword --interfaces 
'0.0.0.0:8000;0.0.0.0:8001:~/openssl/server.crt:~/openssl/server.key'

Then you can use routes.py to re-route, or just do a redirect in your app.

Anthony

On Saturday, December 6, 2014 10:44:32 PM UTC-5, viniciusban wrote:
>
> Is there a way to redirect http to https using routes.py? 
>
> I'm running web2py with the following command: 
> $ python web2py.py --nogui -a adminpassword -c ~/openssl/server.crt -k 
> ~/openssl/server.key -i 0.0.0.0 -p 8000 
>
> This way, web2py doesn't accept http connections. It returns a "Bad 
> Request" error. So, I'd like to make a redirect in routes.py but I 
> couldn't realize how to make it work. 
>
> Any ideia? 
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to