У меня есть несколько веб-проектов на моем localhost Ubuntu 14.04 VM, который я пытаюсь запустить с помощью apache2.
Когда я открываю свой веб-браузер и перехожу к http://localhost:80, он будет загружать apache2-graphite.conf. Когда я пытаюсь загрузить localhost:80/grafana из своего веб-браузера, он все равно будет загружать apache2-graphite.conf, но не grafana.conf? Я пытаюсь показать мой сайт grafana, который хранится в / var / www / grafana / public_html. Может кто-нибудь объяснить, почему он всегда загружает apache2-graphite.conf
Ниже приведены команды / файлы, которые я прикрепляю
sudo a2ensite apache2-graphite
sudo a2ensite grafana
sudo service apache reload
root @ marshell: vi / etc / apache2 / sites -available / apache2-graphite.conf
<VirtualHost *:80>
WSGIDaemonProcess _graphite processes=5 threads=5 display-name='%{GROUP}' inactivity-timeout=120 user=_graphite group=_graphite
WSGIProcessGroup _graphite
WSGIImportScript /usr/share/graphite-web/graphite.wsgi process-group=_graphite application-group=%{GLOBAL}
WSGIScriptAlias / /usr/share/graphite-web/graphite.wsgi
Alias /content/ /usr/share/graphite-web/static/
<Location "/content/">
SetHandler None
</Location>
ErrorLog ${APACHE_LOG_DIR}/graphite-web_error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/graphite-web_access.log combined
</VirtualHost>
root @ marshell: vi /etc/apache2/sites-available/grafana.conf
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName grafana
ServerAlias www.127.0.0.1:80/grafana
DocumentRoot /var/www/grafana/public_html
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>