Maxの日記: [外鯖] Apache+mod_frontpage w/pound(1)
日記 by
Max
Pound越しにapacheでFrontPageな仮想ホストを立てる。
家鯖の既存のコンテンツの多くはこれで作られているので必須。
/etc/pound.cfgに仮想ホストURLに対するリダイレクトを
記述し、/etc/httpd/conf/vhost/Vhosts.confにNameVirtualHostを
追加。ルートWebに対してもVirtualHostを設定しておく必要がある。
/etc/pound/pound.cfg--------------
# frontpage enabled http for apache
UrlGroup ".*"
HeadRequire Host ".*fuga.hogehoge.*"
BackEnd 127.0.0.1,80,1
#Session 300
EndGroup
/etc/httpd/conf/vhost/Vhosts.conf----
<VirtualHost 127.0.0.1>
DocumentRoot /var/www/html
ServerName www.fubyshare.net
<IfModule mod_frontpage.c>
FrontpageDisable
</IfModule>
<Directory "/var/www/html">
Options Indexes Includes FollowSymlinks
AllowOverride None
</Directory>
</VirtualHost>
<VirtualHost 127.0.0.1>
DocumentRoot /var/www/virtual/fuga
ServerName fuga.hogehoge
<IfModule mod_frontpage.c>
FrontpageEnable
FrontpageAdminEnable
</IfModule>
<Directory "/var/www/virtual/fuga">
Options Indexes Includes FollowSymlinks
AllowOverride All
</Directory>
</VirtualHost>
・・・これで/var/www/virtual/fugaに適当なindex.htmlをおいて
アクセスしてみる。が、forbiddenとなってうまくいかない。
ログを見ると、
[error] [client 127.0.0.1] client denied by server configuration:
/var/www/virtual/fuga
なんてのが出ている。
アクセス拒否するような設定はしてないのだが・・・
突っ込んで調べ必要。
家鯖の既存のコンテンツの多くはこれで作られているので必須。
/etc/pound.cfgに仮想ホストURLに対するリダイレクトを
記述し、/etc/httpd/conf/vhost/Vhosts.confにNameVirtualHostを
追加。ルートWebに対してもVirtualHostを設定しておく必要がある。
/etc/pound/pound.cfg--------------
# frontpage enabled http for apache
UrlGroup ".*"
HeadRequire Host ".*fuga.hogehoge.*"
BackEnd 127.0.0.1,80,1
#Session 300
EndGroup
/etc/httpd/conf/vhost/Vhosts.conf----
<VirtualHost 127.0.0.1>
DocumentRoot /var/www/html
ServerName www.fubyshare.net
<IfModule mod_frontpage.c>
FrontpageDisable
</IfModule>
<Directory "/var/www/html">
Options Indexes Includes FollowSymlinks
AllowOverride None
</Directory>
</VirtualHost>
<VirtualHost 127.0.0.1>
DocumentRoot /var/www/virtual/fuga
ServerName fuga.hogehoge
<IfModule mod_frontpage.c>
FrontpageEnable
FrontpageAdminEnable
</IfModule>
<Directory "/var/www/virtual/fuga">
Options Indexes Includes FollowSymlinks
AllowOverride All
</Directory>
</VirtualHost>
・・・これで/var/www/virtual/fugaに適当なindex.htmlをおいて
アクセスしてみる。が、forbiddenとなってうまくいかない。
ログを見ると、
[error] [client 127.0.0.1] client denied by server configuration:
/var/www/virtual/fuga
なんてのが出ている。
アクセス拒否するような設定はしてないのだが・・・
突っ込んで調べ必要。
[外鯖] Apache+mod_frontpage w/pound(1) More ログイン