Aug 6, 2012 -
mac
No Comments


Open Apache and Web Sharing on Mountain Lion
mac sites还没开出来,如何工作?
10.8 居然默认没有web sharing,fuck
只好手动开启了
$ sudo apachectl start
这个页面它位于 /Library/WebServer/Documents/ 下,这是Apache的默认根目录。
但我需要的根目录是位于 ~/Sites 下,继续配置
$ ls /etc/apache2/users/
Guest.conf
我需要一个ares.conf
$ cd /etc/apache2/users/&&sudo vi ares.conf
贴入以下内容
<Directory "/Users/ares/Sites/"> Options Indexes MultiViews AllowOverride All Order allow,deny Allow from all </Directory>
保存,退出,重启apache
$ sudo apachectl restart
再把以前Sites下的index.html 复制回去,就可以看到Sites下的默认首页了