द्वारा चलाए जा रहे एक WSGI स्क्रिप्ट के प्रमाणीकरण जानकारी पचाने मैं निर्देशapache2 पासिंग mod_wsgi
<VirtualHost *>
<Location />
AuthType Digest
AuthName "global"
AuthDigestDomain/
AuthUserFile /root/apache_users
<Limit GET>
Require valid-user
</Limit>
</Location>
WSGIScriptAlias//some/script.wsgi
WSGIDaemonProcess mywsgi user=someuser group=somegroup processes=2 threads=25
WSGIProcessGroup mywsgi
ServerName some.example.org
</VirtualHost>
मैं /some/script.wsgi में जानना चाहते हैं मिल गया है
def application(environ, start_response):
start_response('200 OK', [
('Content-Type', 'text/plain'),
])
return ['Hello']
क्या उपयोगकर्ता लॉग इन है
मैं यह कैसे कर सकता हूं? mod_wsgi documentation पर
def application(environ, start_response):
start_response('200 OK', [
('Content-Type', 'text/plain'),
])
return ['Hello %s' % environ['REMOTE_USER']]
अधिक जानकारी:
अधिक, बहुत बाध्य। –