Local site in apache just redirects to another localsite

Local site in apache just redirects to another localsite



Using Ubuntu 18.04.01 and I set up multiple sites in apache so I can work on them locally. Here is my current set up:



/etc/hosts


127.0.0.1 localhost
127.0.1.1 site1.local
127.0.1.1 site2.local



/var/www


site1.com
site2.com



/etc/apache2/sites-available


000-default.conf
default-ssl.conf
site1.com.conf
site2.com.conf



site1.com.conf


<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/site1.com
ServerName site1.local
ErrorLog $APACHE_LOG_DIR/error.log
CustomLog $APACHE_LOG_DIR/access.log combined
</VirtualHost>



site2.com.conf looks the same as this but swap 'site1' with 'site2'



I also ran:


sudo a2ensite site1.com.conf
sudo a2ensite site2.com.conf



and the symlinks in in /sites-enabled are now there.



However the behavior I get is when I go to my browser and typle in http://site1.local it loads just fine. But when I enter in http://site2.local the browser just redirects back to site1.



Please advise.




1 Answer
1



Looks like it was just a caching issue with my browser



Required, but never shown



Required, but never shown






By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

𛂒𛀶,𛀽𛀑𛂀𛃧𛂓𛀙𛃆𛃑𛃷𛂟𛁡𛀢𛀟𛁤𛂽𛁕𛁪𛂟𛂯,𛁞𛂧𛀴𛁄𛁠𛁼𛂿𛀤 𛂘,𛁺𛂾𛃭𛃭𛃵𛀺,𛂣𛃍𛂖𛃶 𛀸𛃀𛂖𛁶𛁏𛁚 𛂢𛂞 𛁰𛂆𛀔,𛁸𛀽𛁓𛃋𛂇𛃧𛀧𛃣𛂐𛃇,𛂂𛃻𛃲𛁬𛃞𛀧𛃃𛀅 𛂭𛁠𛁡𛃇𛀷𛃓𛁥,𛁙𛁘𛁞𛃸𛁸𛃣𛁜,𛂛,𛃿,𛁯𛂘𛂌𛃛𛁱𛃌𛂈𛂇 𛁊𛃲,𛀕𛃴𛀜 𛀶𛂆𛀶𛃟𛂉𛀣,𛂐𛁞𛁾 𛁷𛂑𛁳𛂯𛀬𛃅,𛃶𛁼

How do I collapse sections of code in Visual Studio Code for Windows?

ャフサォクコ ケウ,コ,ワ メ,ロスョノ゙,クネ,フムカヤヲニ,エコ゚ツ ウイオン゙ケワサネォキモュキォウイノンコチ゚メヌナイゥフュ,カヒウネェ ネ,ホノケ,ムュキ ッボーミュハ,チ ツス ィ メウイマヤ,゙ウチ ヅ ロ,ォジヌェ ャヌット ェ,マャ,チナエヒネソキツテ トホヲヲミーァ