【发布时间】:2016-09-11 16:10:26
【问题描述】:
当我这样做时:
sudo a2dissite
我明白了
Your choices are:
意味着所有网站都被禁用。
当我将我的 IP 本地网络地址输入浏览器时,我会得到默认的 Apache 页面。
http://192.168.1.101/ (putting this in the browser address bar gets me the default apache page)
使用
停止 apachesudo service apache2 stop
给我“无法访问此站点”,因此 apache 正在提供该默认页面。
那么,当没有启用任何站点时显示 apache 默认页面是否合适?
跟进:如何将不同的目录设为默认目录?我有一个 test.conf 设置
<VirtualHost 127.0.0.2:80>
ServerAdmin webmaster@localhost
DocumentRoot /home/myusername/websites/wp-test-site/site
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
我认为启用它会使默认站点文件夹成为 /home/myusername/websites/wp-test-site/site,但事实并非如此。
是的,我正在使用 sudo 重新启动。
【问题讨论】:
标签: apache2