所以我有Trac在我的debian服务器上运行,VirtualHost文件如下所示:
... WSGIScriptAlias / /srv/domain/trac.wsgi WSGIScriptReloading On <Directory /srv/domain/tracprojects> WSGIApplicationGroup %{GLOBAL} Order deny,allow Deny from all </Directory> ...
我认为这可能会拒绝所有人(我想要做的testing,这将工作)。 尽pipetrac应用程序仍在运行,但这并不影响安装。
有什么我需要把我的wsgi文件来限制访问,而不是在我的虚拟主机文件?
你应该使用:
WSGIScriptAlias / /srv/domain/trac.wsgi <Directory /srv/domain/> WSGIApplicationGroup %{GLOBAL} Order deny,allow Deny from all </Directory>
这可能会阻止其他东西,以及该目录下,所以使用,而不是:
WSGIScriptAlias / /srv/domain/trac.wsgi <Directory /srv/domain/tracprojects> WSGIApplicationGroup %{GLOBAL} Order deny,allow <Files trac.wsgi> Deny from all </Files> </Directory>
顺便说一句,你不需要WSGIScriptReloading。
另外请确保你阅读:
使用守护进程模式将是首选。
Trac的一般设置说明: