mod-wsgi

pywintypes27.dll not found using Apache, Django, pywin32, Python2.7 and mod_wsgi

Deadly 提交于 2019-12-07 08:44:11
问题 I have a Django application using django-mssql to communicate w/ SQL Server. This works just fine in the dev server (runserver) but under Apache/mod-wsgi, I get a error related to it trying to find a .dll which does exist: Exception Type: ImportError Exception Value: No system module 'pywintypes' (pywintypes27.dll) Exception Location: C:\Python27\lib\site-packages\win32\lib\pywintypes.py in __import_pywin32_system_module__, line 98 Python Executable: C:\Program Files (x86)\Apache Software

“DLL load failed” when using mercurial on trac

旧城冷巷雨未停 提交于 2019-12-07 05:02:31
问题 My mercurial repository works correctly in trac when I use the tracd server. However, when I use apache , I get the following warning at the top of all trac pages: Warning: Can't synchronize with repository "(default)" (Unsupported version control system "hg": DLL load failed: The specified module could not be found.). Look in the Trac log for more information. The trac log doesn't have anything useful except a warning about mercurial being compiled with Python 2.6.2 and the actual version of

Django + Apache + Windows WSGIDaemonProcess Alternative

微笑、不失礼 提交于 2019-12-07 04:48:46
问题 After setting up a django site and running on the dev server, I have finally gotten around to figuring out deploying it in a production environment using the recommended mod_wsgi/apache22. I am currently limited to deploying this on a Windows XP machine. My problem is that several django views I have written use the python subprocess module to run programs on the filesystem. I keep getting errors when running the subprocess.Popen I have seen several SO questions that have asked about this,

deploying a WSGI application on mod_python

巧了我就是萌 提交于 2019-12-07 04:08:31
问题 I wrote a WSGI application which I need to deploy to a server, however I've been given a server that already has mod_python installed. I am not allowed to remove mod_python since there are some mod_python applications running on it already. One option I considered was installing mod_wsgi alongside mod_python, however I went through sources and found that was a bad idea. Apparently mod_wsgi and mod_python don't mix well. Another option I considered was installing mod_fastcgi and deploying it

Python modules autoloader?

北战南征 提交于 2019-12-07 04:01:02
问题 How can I autoload all my modules that kept in different directories and sub directories? I have seen this answer which is using __import__ , but it is still not the autoload that I have in mind. I'm thinking something similar to PHP autoloader. Even better something like Composer autoloader. It seems that autoloader is not a popular thing in Python from the research I have gathered so far (can't be sure as I'm new in Python). Is autoloading something not encourage-able in Python? My autoload

WSGI as AuthFormProvider

半腔热情 提交于 2019-12-07 03:21:23
Is it possible to use 'wsgi' as an AuthFormProvider in Apache2.4? As a first attempt I edited the examples found here . The configuration now looks like this but does not work: <Location "/test"> AuthType Form AuthFormProvider wsgi AuthName "test" AuthFormLoginRequiredLocation /login.html WSGIAuthUserScript /path/to/django/wsgi.py WSGIAuthGroupScript /path/to/django/wsgi.py Require Group test Require valid-user Session On SessionCookieName xyz path/ SessionCrypotPassphrase 123456789 </Location> For a start, you must be using mod_wsgi 4.3.0 for WSGIAuthGroupScript to work with Apache 2.4. The

Django mod_wsgi apache

房东的猫 提交于 2019-12-07 03:05:37
问题 When I try to visit my Django site at http://www.satoshi.example.com/mysite I get a 503 Service Temporary Unavailable . The Apache error log says [Tue Feb 28 07:11:09 2012] [error] [client 10.0.0.202] (13)Permission denied: mod_wsgi (pid=4756): Unable to connect to WSGI daemon process 'django' on '/etc/httpd/logs/wsgi.17555.4.1.sock' after multiple attempts. Apache properly loads mod_wsgi root@satoshi:~/html/mysite# apachectl -M | grep wsgi wsgi_module (shared) Syntax OK Apache loads /var/www

apache2 and mod wsgi : Target WSGI script cannot be loaded as Python module

核能气质少年 提交于 2019-12-07 01:15:20
问题 I am trying to install mod_wsgi on apache2, on ubuntu. So I install libapache2-mod-wsgi package, I activate him with a2enmod. I got a web site (languageAnalyz), that I am trying to use with mod_wsgi. When I call localhost/languageAnalyz, I got an error 500. In apache2 log, I can see this : [Sun Aug 25 11:28:21 2013] [error] [client 127.0.0.1] mod_wsgi (pid=4993): Target WSGI script '/var/www/languageAnalyz/test-wsgi.py' cannot be loaded as Python module. [Sun Aug 25 11:28:21 2013] [error]

OperationalError: attempt to write a readonly database in ubuntu server

谁说胖子不能爱 提交于 2019-12-07 00:45:33
问题 I'm running a FlaskApp using mod_wsgi and apache2 on Ubuntu server. I tried running the flask app on localhost successfully and then deployed it on ubuntu server. But when i try to update database, its giving error: Failed to update model. (OperationalError) attempt to write a readonly database u'UPDATE mysongs SET songurl=? WHERE songid.id = ?' (u'www.site.com/I_wanna_dance', 1) Now i tried look for database file permission which is: -rwxr-xr-x 1 www-data www-data 10240 Jul 14 15:35 /var/www

session issue with django+apache+mod_wsgi

社会主义新天地 提交于 2019-12-06 14:21:33
问题 I've written a django application, and put it on a CentOS server. It is definitely okay when I use django development web server. Such as I start it by "python ./manage.py runserver", and access that server from browser on another computer. I can sign in one time, and access all the pages without issues. However when I run it with apache+mod_wsgi, I just found I have to login with user and password time by time. I think maybe there is some problem with the session middleware, so, how can I