1 |
Te respondo con un pedazo de conf :) |
2 |
de un server que tiene un par de dominios. |
3 |
|
4 |
NameVirtualHost 66.250.30.24 |
5 |
|
6 |
########################################################################### |
7 |
# WWW.FMLIBERTADOR.COM.UY |
8 |
########################################################################### |
9 |
<VirtualHost 66.250.30.24> |
10 |
|
11 |
ServerAdmin admin@××××××××××××××××.uy |
12 |
ServerName www.fmlibertador.com.uy |
13 |
ServerAlias fmlibertador.com.uy |
14 |
DocumentRoot /home/httpd/www.fmlibertador.com.uy/htdocs |
15 |
AddType application/x-httpd-php .php .php4 .php3 .phtml |
16 |
.phtm |
17 |
AddType application/x-httpd-php-source .phps |
18 |
ScriptAlias /cgi-bin/ |
19 |
/home/httpd/www.fmlibertador.com.uy/cgi-bin/ |
20 |
Setenv VLOG |
21 |
/home/httpd/www.fmlibertador.com.uy/logs/fmlibertador.com.uy-acces.vlog |
22 |
ErrorLog |
23 |
/home/httpd/www.fmlibertador.com.uy/logs/fmlibertador.com.uy-error.log |
24 |
CustomLog |
25 |
/home/httpd/www.fmlibertador.com.uy/logs/fmlibertador.com.uy-acces.log |
26 |
common |
27 |
|
28 |
<Directory /> |
29 |
Options -Indexes FollowSymLinks MultiViews |
30 |
AllowOverride All |
31 |
Order allow,deny |
32 |
Allow from all |
33 |
</Directory> |
34 |
|
35 |
<Directory /cgi-bin/> |
36 |
AllowOverride All |
37 |
Options ExecCGI |
38 |
Order allow,deny |
39 |
Allow from all |
40 |
</Directory> |
41 |
|
42 |
</VirtualHost> |
43 |
|
44 |
########################################################################### |
45 |
# WWW.JUEGOSENRED.COM.UY |
46 |
########################################################################### |
47 |
<VirtualHost 66.250.30.24> |
48 |
ServerAdmin admin@×××××××××××××××.uy |
49 |
ServerName www.juegosenred.com.uy |
50 |
ServerAlias juegosenred.com.uy |
51 |
DocumentRoot /home/httpd/www.juegosenred.com.uy/htdocs |
52 |
AddType application/x-httpd-php .php .php4 .php3 .phtml |
53 |
.phtm |
54 |
AddType application/x-httpd-php-source .phps |
55 |
ScriptAlias /cgi-bin/ |
56 |
/home/httpd/www.juegosenred.com.uy/cgi-bin/ |
57 |
Setenv VLOG |
58 |
/home/httpd/www.juegosenred.com.uy/logs/juegosenred.com.uy-acces.vlog |
59 |
ErrorLog |
60 |
/home/httpd/www.juegosenred.com.uy/logs/juegosenred.com.uy-error.log |
61 |
CustomLog |
62 |
/home/httpd/www.juegosenred.com.uy/logs/juegosenred.com.uy-acces.log |
63 |
common |
64 |
<Directory /> |
65 |
Options -Indexes FollowSymLinks MultiViews |
66 |
AllowOverride All |
67 |
Order allow,deny |
68 |
Allow from all |
69 |
</Directory> |
70 |
<Directory /cgi-bin/> |
71 |
AllowOverride All |
72 |
Options ExecCGI |
73 |
Order allow,deny |
74 |
</Directory> |
75 |
|
76 |
</VirtualHost> |
77 |
|
78 |
Luego se repite en los demas dominios .. espero te sirva |
79 |
cheers. |
80 |
|
81 |
|
82 |
|
83 |
On Wed, 2003-06-18 at 16:58, Facundo Ortiz wrote: |
84 |
|
85 |
> Hola a todos: |
86 |
> Tengo un problema que me está rompiendo la cabeza. Tengo un apache |
87 |
> atendiendo a un sitio fund.homelinux.net, en donde quiero tener puesto otro |
88 |
> sitio independiente aulavirtual.homelinux.net(los dos con el mismo ip). Para |
89 |
> eso estoy configurando vhosts.conf, pero resulta que al navegar en cada |
90 |
> dirección siempre me abre el mismo sitio. |
91 |
> Tengo los módulos configurados, pero el problema es que (según la |
92 |
> configuración que pongo abajo), con cualquiera de las dos direcciones me va |
93 |
> siempre al mismo directorio, /home/httpd/htdocs. Qué me está faltando??? |
94 |
> Lo que quiero es que cada dirección me remita a carpetas distintas del |
95 |
> disco (donde tengo cada sitio). Revisé el manual(de hecho lo copié de allí), |
96 |
> pero necesito alguien que sepa más... |
97 |
> Mil gracias |
98 |
> Facundo |
99 |
> ((PD: Les aclaro mi configuración: mi webserver tiene una ip privada |
100 |
> (10.0.0.5), y sale a internet por un firewall, que es la que tiene la ip |
101 |
> pública... No sé si tendrá que ver, a lo mejor es éso lo que no deja que |
102 |
> funcione...)) |
103 |
> |
104 |
> ((Vhosts.conf)) |
105 |
> ################# Named VirtualHosts |
106 |
> |
107 |
> NameVirtualHost * |
108 |
> |
109 |
> <VirtualHost *> |
110 |
> ServerName fund.homelinux.net |
111 |
> ServerPath / |
112 |
> DocumentRoot /home/httpd/htdocs |
113 |
> </VirtualHost> |
114 |
> |
115 |
> <VirtualHost *> |
116 |
> ServerName aulavirtual.homelinux.net |
117 |
> ServerPath /moodle |
118 |
> DocumentRoot /home/httpd/htdocs/moodle |
119 |
> </VirtualHost> |
120 |
> |
121 |
> |
122 |
> |
123 |
> |
124 |
> -- |
125 |
> gentoo-user-es@g.o mailing list |
126 |
> |