1

I have wrote site on Pyramid framework (Python) and bought VPS (OpenVZ technology) server.

I'm new to server administration and there is no much docs on how to configure Nginx with Python and Pyramid.

Maybe question is very poor from first sight, but I have a big gap in server's configure technology knowledge. Maybe there are useful links for my question I haven't found.

Thanks in advance!

1 Answers1

3

Both Pyramid and Nginx have very good documentation, independently. I assume you've built your site locally with Waitress or Paster serving the content. Essentially, from within Nginx's config, you are just going to direct incoming traffic from port 80 (the usual port for website traffic) to your Paster/Waitress port (e.g. 8000, 6543, etc.). There are some additional tips in the link below regarding making sure Nginx (which will be your "reverse proxy") passes along the Host headers to Paster/Waitress, so your Pyramid app can generate correct url's within.

http://docs.pylonsproject.org/projects/pyramid_cookbook/en/latest/deployment.html#nginx-paster-supervisord

http://docs.pylonsproject.org/projects/waitress/en/latest/#using-behind-a-reverse-proxy

Raj
  • 131
  • 2