Indico安装上禁止403 Apache错误

时间:2017-06-15 00:26:06

标签: apache python-2.7 ubuntu mod-wsgi wsgi

我安装了Indico http://indico-software.org/这是一个开源工具,用于在Ubuntu上进行事件组织,归档和协作,并提供此指令https://indico.syntek.org/category/1/material/0/0.pdf,安装看起来不错但是当我尝试打开localhost / indico时,我得到了一个禁止403错误。

我将这些行添加到/etc/apache2/apach2.conf

WSGIScriptAlias / /opt/indico/htdocs/
WSGIPythonHome /usr/local/pythonenv/BASELINE
WSGIPythonPath 
    /usr/local/pythonenv/indico12/lib/python2.7/sitepackages
WSGIPythonEggs /opt/indico/tmp/egg-cache 

<Directory /opt/indico/htdocs>
    Options Indexes FollowSymLinks
    AllowOverride None
<Files indico.wsgi>
    Require all granted
</Files>
</Directory>

这是我在/etc/apache2/sites-available/a2indico.conf上的virtulhost文件

<VirtualHost *:80>

     ErrorLog /var/log/apache2/error.log
        LogLevel warn

     Alias /indico/images "/opt/indico/htdocs/images"
     Alias /indico/css "/opt/indico/htdocs/css"
     Alias /indico/js "/opt/indico/htdocs/js"
     Alias /indico/ihelp "/opt/indico/htdocs/ihelp"

     WSGIDaemonProcess WSGIDAEMON processes=32 threads=1 inactivity-
timeout=3600 maximumrequests=10000 python-
path=/usr/local/pythonenv/indico12/lib/python2.7/site-packages python-
eggs=/opt/indico/tmp/egg-cache

     WSGIScriptAlias /indico "/opt/indico/htdocs/indico.wsgi"

     <Directory "/opt/indico">
        WSGIProcessGroup WSGIDAEMON
        WSGIApplicationGroup %{GLOBAL}
        AllowOverride None
        Options FollowSymLinks
        Require all granted
     </Directory>
</VirtualHost>

/ etc / apach2和/ opt / indico directorys的chown适用于www-data用户。

非常感谢你的帮助。

Plz给我一些建议。 =)

1 个答案:

答案 0 :(得分:0)

您可能没有登陆新创建的虚拟主机,它没有ServerName或ServerAlias。 not将向您显示您拥有的其他虚拟主机。即使在此处指定ServerName或ServerAlias之后,您可能还需要修改默认(000默认)虚拟主机,因为它可能隐式使用您的本地系统名称作为ServerNAme(ubuntu将其留空,这可以隐藏以后的虚拟主机!)