Apache 500内部服务器错误 - DJANG

2024-06-26 00:19:22 发布

您现在位置:Python中文网/ 问答频道 /正文

以下错误消息有问题:

Error: "500 Internal Server Error"

İ在apache2上启动django项目。

APACHE2配置文件:

<VirtualHost *:80>
ServerAdmin biisguzar@gmail.com
ServerName asistan.com
ServerAlias www.asistan.com
DocumentRoot /var/www/asistan


Alias /static/ /var/www/asistan/static/
WSGIScriptAlias / "/var/www/asistan/asistan/wsgi.py"


<Directory /var/www/asistan>
Order allow,deny
Allow from all
</Directory>


</VirtualHost>

DJANGO WSGİ.PY FİLE:

import os,sys
sys.path.append('/var/www')
sys.path.append('/var/www/asistan')

sys.path.append('/var/www/asistan/asistan')
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "asistan.settings")

from django.core.wsgi import get_wsgi_application
application = get_wsgi_application()

第SS页:

enter image description here


Tags: pathdjangofromcomwsgiapplicationvarwww