我已经正确安装了所有内容,并通过了与该主题相关的所有解决方案,但是仍然存在错误,我是Django的新手,非常感谢您的帮助
我在错误日志文件中收到此错误:
[[Fri Feb 14 21:52:16.916422 2020] [authz_core:error] [pid 4288:tid 1252] [client :: 1:51391] AH01630:服务器配置拒绝了客户端:E:/ AppSource / eCommerce / src / ecommerce / wsgi_windows.py
并且当我尝试达到127.0.0.1:80时,我得到了:禁止的403
这是我的wsgi_windows.py配置:
activate_this = 'CE:/AppSource/eCommerce/Scripts/activate_this.py'
exec(open(activate_this).read(),dict(__file__=activate_this))
import os
import sys
import site
from django.core.wsgi import get_wsgi_application
site.addsitedir("C:/Python37/Lib/site-packages")
sys.path.append('E:/AppSource/eCommerce')
sys.path.append('E:/AppSource/eCommerce/src')
sys.path.append('E:/AppSource/eCommerce/src/ecommerce')
os.environ['DJANGO_SETTINGS_MODULE'] = 'ecommerce.settings'
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "ecommerce.settings")
application = get_wsgi_application()
这是hhtpd-vhosts.conf配置:
<VirtualHost *:80>
ServerName localhost
WSGIPassAuthorization On
ErrorLog "E:/appSource/eCommerce/eCommerce.error.log"
CustomLog "E:/appSource/eCommerce/eCommerce.access.log" combined
WSGIScriptAlias / "E:/appSource/eCommerce/src/ecommerce/wsgi_windows.py"
<Directory "E:/appSource/eCommerc/src/ecommerce/">
<Files wsgi_windows.py>
Require all granted
</Files>
</Directory>
Alias /static "E:/appSource/eCommerce/static_cdn/static_root"
<Directory "E:/appSource/eCommerce/static_cdn/static_root">
Require all granted
</Directory>
Alias /media "E:/appSource/eCommerce/static_cdn/media_root"
<Directory "E:/appSource/eCommerce/static_cdn/media_root">
Require all granted
</Directory>
</VirtualHost>
我已经尝试了我所知道的一切请帮忙解决这个问题谢谢