【发布时间】:2015-12-30 09:18:52
【问题描述】:
我有一个使用 Django 构建的 Web 应用程序。它需要用户上传 一份文件。但是,当我在最终生产中进行部署时 我收到此错误消息:
我应该使用什么指令来更改 HTTPD.CONF?
目前我的看起来像这样:
WSGISocketPrefix /u33/app/www/foobar/run
<VirtualHost *:8061>
ServerAdmin coolguy@cool_univ.ac.id
DocumentRoot /u33/app/www/foobar/html
ServerName foo.ac.co.id
ErrorLog logs/foobar-error_log
CustomLog logs/foobar-access_log common
ErrorLog /u33/app/www/foobar/logs/error_log
ServerAlias foobar.com
SetOutputFilter DEFLATE
SetEnvIfNoCase Request_URI "\.(?:gif|jpe?g|png)$" no-gzip
RewriteEngine on
#RewriteCond %{REQUEST_URI} !/
#RewriteRule ^ %{REQUEST_URI}/ [R=302,L]
Alias /static/ /u33/app/www/foobar/html/
RewriteCond %{REQUEST_URI} ^/example1$
RewriteRule ^(.+) http://cool_univ.ac.id/foobar/#/148/target-predictions [NE,R=302]
<Directory "/u33/app/www/foobar/html/">
Options FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<Directory "/u33/app/www/foobar/cgi-bin">
AllowOverride None
#Options None
Options FollowSymLinks
Order allow,deny
Allow from all
</Directory>
WSGIApplicationGroup %{GLOBAL}
WSGIDaemonProcess foobar.com python-path=/u33/app/www/foobar/wsgi-scripts:/usr/lib/python2.7/site-packages:/u21/ewijaya/.anaconda/lib/python2.7/site-packages processes=2 threads=15 display-name=%{GROUP}
WSGIProcessGroup foobar.com
WSGIScriptAlias / /u33/app/www/foobar/wsgi-scripts/webframework/wsgi.py process-group=foobar.com
</VirtualHost>
【问题讨论】:
-
2年后你找到方法了吗?
标签: apache file-upload httpd.conf