Last active
July 25, 2020 12:22
-
-
Save william-condori/33798d41fa3482380630093a369d0ae9 to your computer and use it in GitHub Desktop.
Configuración de Virtual Host en XAMP
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Configuración de Virtual Host XAMP | |
- Primeramente debemos configurar una ip fija en la máquina que se encenderá XAMP | |
- Segundo : Vamos al archivo C:/Windows/System32/drivers/etc/host | |
Ahí dentro vamos declarando los host virtuales. Ejemplo: | |
# localhost name resolution is handled within DNS itself. | |
# 127.0.0.1 localhost | |
# ::1 localhost | |
# Ip fija | |
192.168.0.10 my-appointments.web | |
# LOCALHOST | |
127.0.0.1 localhost | |
::1 localhost | |
# SITIOS | |
127.0.0.1 blogs.web | |
::1 blogs.web | |
- Tercero : Vamos al archivo 'httpd-vhosts.conf' en mi caso la ruta es D:/Xamp/apache/conf/extra/httpd-vhosts.conf | |
Dentro del archivo vamos creando los host virtuales, Ejemplo : | |
## Ruta IP fija | |
<VirtualHost 192.168.0.10:80> | |
DocumentRoot "D:/Xamp/htdocs/My-Appointment-Web/public" | |
ServerName my-appointments.web | |
</VirtualHost> | |
## Ruta en mi máquina | |
<VirtualHost localhost:80> | |
DocumentRoot "D:/Xamp/htdocs" | |
ServerName localhost | |
</VirtualHost> | |
<VirtualHost blogs.web:80> | |
DocumentRoot "D:/Xamp/htdocs/blogs" | |
ServerName blogs.web | |
</VirtualHost> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment