我有一个django项目,已在服务器上使用apache2进行了部署。我目前通过我的IP地址访问此地址。但是我希望项目的apache'root'(?)是IP_address / django_project /
我曾尝试在apache2 000-default.conf文件中更改ServerName,但似乎无法正常工作...
000-default.conf:
<VirtualHost *:80>
ServerName results
ServerAlias results
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
WSGIDaemonProcess results python-home=/home/django/config/env python-path=/usr/local/Databases/results
WSGIProcessGroup results
WSGIScriptAlias / /usr/local/Databases/results/django_project/wsgi.py
<Directory /usr/local/Databases/results/django_project>
<Files wsgi.py>
Require all granted
</Files>
</Directory>
Alias /static/ /usr/local/Databases/results/static/
<Directory /usr/local/Databases/results/static>
Require all granted
</Directory>
<Directory /usr/local/Databases/results>
Deny from all
Allow from *<subnet>*
</Directory>
</VirtualHost>
如何进行设置,以便通过新的“ root”访问该项目?
谢谢