[請益] Apache 新增虛擬主機
打擾了各位先進
小弟想要新增一個虛擬主機到 /home/user/example
但是似乎是失敗了,也不知道怎樣算是新增成功。
以下是新增的作法
在/apache2/sites-available下新增example.conf 以下為檔案內容
<VirtualHost *:80>
ServerAdmin webmaster@example
DocumentRoot /home/user/example
<Directory /home/user/example>
Options all
AllowOverride all
Require all granted
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
--------------------------------------------------
/home/user/example跟裡面index.php的own user, grp www-data, mod 755 都一樣
結果
a2ensite enabled
apache2 也restart OK
不曉得怎樣才算是新增成功,也不知道要輸入什麼網址去跑example下的index.php
谷歌兩天了還是無法成功,所以想請問一下有什麼其他的建議.....
--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 182.235.169.247
※ 文章網址: https://www.ptt.cc/bbs/PHP/M.1423303185.A.08D.html
※ 編輯: olop (182.235.169.247), 02/07/2015 18:01:09
→
02/07 18:44, , 1F
02/07 18:44, 1F
→
02/07 18:45, , 2F
02/07 18:45, 2F
→
02/07 18:46, , 3F
02/07 18:46, 3F
→
02/07 18:47, , 4F
02/07 18:47, 4F
→
02/07 18:56, , 5F
02/07 18:56, 5F
討論串 (同標題文章)
完整討論串 (本文為第 1 之 2 篇):
PHP 近期熱門文章
PTT數位生活區 即時熱門文章