Launch Django as a Windows Service

I am running Django on Windows Server 2k3 under Nginx using FastCGI.

Nginx runs as a Windows service and is easy to manage and autostart. Nginx works with WINSW .

I want to do the same for a Django application and you need to find a way to do this.

Django should be run as a standalone FCGI application with this command:

python manage.py runfcgi method=threaded host=127.0.0.1 port=8800

or

manage.py runfcgi method=threaded host=127.0.0.1 port=8800 

(if .py linked to python)

I am looking for a way to start / stop FCGI Django as a Windows service, to be able to autostart when Windows boots up and have an easy way to start / stop / restart a Django FCGI application.

+3
source share
1 answer
0

Source: https://habr.com/ru/post/1739477/


All Articles