(duvida) Configurar Virtual Hosts Debian Wheezy

1. (duvida) Configurar Virtual Hosts Debian Wheezy

Sergio A. Oliviera
SergioAOliveira

(usa Debian)

Enviado em 05/11/2013 - 10:25h

Bom dia Galera.

Não estou conseguindo configurar o debian para rodar as Virtual hosts. Configurei os arquivos conforme segue abaixo:

/etc/hosts


127.0.0.1 localhost
127.0.1.1 likeweb-kumon
127.0.1.1 likeweb-storenow


# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters




/etc/apache2/conf-available/httpd.conf

#personalizar erros
#ErrorDocument 404 /erros/404.html
#ErrorDocument 500 /erros/500.html

#ErrorDocument 400 /error/HTTP_BAD_REQUEST.html.var
#ErrorDocument 401 /error/HTTP_UNAUTHORIZED.html.var
#ErrorDocument 403 /error/HTTP_FORBIDDEN.html.var
#ErrorDocument 404 /erros/404.html
#ErrorDocument 405 /error/HTTP_METHOD_NOT_ALLOWED.html.var
#ErrorDocument 408 /error/HTTP_REQUEST_TIME_OUT.html.var
#ErrorDocument 410 /error/HTTP_GONE.html.var
#ErrorDocument 411 /error/HTTP_LENGTH_REQUIRED.html.var
#ErrorDocument 412 /error/HTTP_PRECONDITION_FAILED.html.var
#ErrorDocument 413 /error/HTTP_REQUEST_ENTITY_TOO_LARGE.html.var
#ErrorDocument 414 /error/HTTP_REQUEST_URI_TOO_LARGE.html.var
#ErrorDocument 415 /error/HTTP_UNSUPPORTED_MEDIA_TYPE.html.var
ErrorDocument 500 /erros/500.html
#ErrorDocument 501 /error/HTTP_NOT_IMPLEMENTED.html.var
#ErrorDocument 502 /error/HTTP_BAD_GATEWAY.html.var
# ErrorDocument 503 /error/HTTP_SERVICE_UNAVAILABLE.html.var
# ErrorDocument 506 /error/HTTP_VARIANT_ALSO_VARIES.html.var


ServerName 192.168.1.50:80

<VirtualHost *:80>
ServerName likeweb-kumon
DocumentRoot /var/www/kumon
<Directory "/var/www/kumon">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>

<VirtualHost *:80>
ServerName likeweb-storenow
DocumentRoot /var/www/storenow
<Directory "/var/www/storenow">
Options Indexes FollowSymLinks Includes ExecCGI
AllowOverride All
Order allow,deny
Allow from all
</Directory>
</VirtualHost>





/etc/apache2/sites-available/kumon.conf


<VirtualHost *:80>
ServerAdmin soliveira@studiovisual.com.br
ServerName likeweb-kumon
ServerAlias likeweb-kumon
DocumentRoot /var/www/kumon
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>

<Directory /var/www/kumon>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>

ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>


ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, arn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
Alias /doc/ "/usr/share/doc/"


<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
</VirtualHost>


Configurei esses arquivos e depois ativei o site com o comando a2ensite, mas não consigo acessar pela rede, a unica coisa que consegui foi acessar o primeiro virtual host configurado quando digito o nome do servidor, e acesso as pastas de todos os sites quando digito o IP do servidor.


Alguem ai consegue me ajudar ?


  






Patrocínio

Site hospedado pelo provedor RedeHost.
Linux banner

Destaques

Artigos

Dicas

Tópicos

Top 10 do mês

Scripts