Production deployment Django WSGI application on nginx and gunicorn

Following my previous post on nginx installation process, I will now describe the process of deploying a Django WSGI application on nginx. Tero Karvinen has a great guide on his website on deploying Django using Apache 2 webserver and mod_wsgi, which I have adapted to use for nginx. Install virtual environment The first step is to create a new virtual environment inside your directory. In this example, I will store my Django projects in the /home/evgeni/publicwsgi directory, and activate the virtual environment using the following commands:...

June 6, 2023 · 5 min