çalıştırmak çalışırken:WSGIServer hataları burada benim senaryo, Öncelikle Django uygulaması
#!/usr/bin/python
import sys, os
sys.path.append('/home/username/python')
sys.path.append("/home/username/python/flup")
sys.path.append("/home/username/python/django")
# more path stuff
os.environ['DJANGO_SETTINGS_MODULE'] = "project.settings"
from django.core.servers.fastcgi import runfastcgi
runfastcgi(method="threaded", daemonize="false")
olarak here nitelendirildi. Burada
Ve olsun hata olduğunda kabuğundan çalıştırmak çalışıyor:
WSGIServer: missing FastCGI param REQUEST_METHOD required by WSGI!
WSGIServer: missing FastCGI param SERVER_NAME required by WSGI!
WSGIServer: missing FastCGI param SERVER_PORT required by WSGI!
WSGIServer: missing FastCGI param SERVER_PROTOCOL required by WSGI!
Status: 404 NOT FOUND
Content-Type: text/html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html lang="en">
<!-- more html which looks to be the correct output -->
Sorum şu, neden FastCGI tarafından otomatik geçirilen bu parametreler değil mi? Neyi yanlış yapıyorum? Komut dosyasını web sunucumdan yürütmek bana bir iç sunucu hatası veriyor. Yerine Senaryomun son iki hatlarının
, ben
from flup.server.fcgi import WSGIServer
from django.core.handlers.wsgi import WSGIHandler
WSGIServer(WSGIHandler()).run()
kullanabilirsiniz Ama yine aynı hatayı alıyorum ...
Neden mod_wsgi kullanmıyorsunuz? –
@ S.Lott: Birkaç yıl geçti, ancak paylaşılan bir ev sahibiydim. WSGI'ya erişiminiz yoktu. – mpen