0
I want to have two different directories, opened from the same IP, but different ports. I can't find a way to do this, I have tried many different forums, and Google, but still found nothing. Can I create a Virtual Host like that?
Example:
127.0.0.1:80 -> /Applications/AMPPS/www80
127.0.0.1:12 -> /Applications/AMPPS/www12
Yes, I am running on Mac, but the instructions should be the same between Mac and Windows
probably a dumb question, but where is the
sites-available
configuration directory? – Jaketr00 – 2016-09-20T02:48:09.017@Jaketr00 Looks like it may be in
– Lawrence – 2016-09-20T02:52:17.960/etc/apache2/extra/
and might be calledhttpd-vhosts.conf
- according to this link - https://coolestguidesontheplanet.com/set-virtual-hosts-apache-mac-osx-10-10-yosemite/I'm still getting an error, "127.0.0.1 didn’t send any data." I tried both
httpd.conf
andextra/httpd-vhosts.conf
– Jaketr00 – 2016-09-20T02:56:35.413@Jaketr00 Do the apache logs show any attempts or errors when you try and access it? – Lawrence – 2016-09-20T02:58:25.980
both the access logs and error logs show nothing, they are both blank – Jaketr00 – 2016-09-20T03:00:40.973
Does it work with only one VirtualHost configured? – Lawrence – 2016-09-20T03:07:48.340
the original port, 80, still works no matter what, but the second port, 12, doesnt ever work – Jaketr00 – 2016-09-20T03:08:47.703
Ah, I had assumed you had configured Apache to listen on port 12 already. You may need to configure that as well - https://httpd.apache.org/docs/2.4/bind.html
– Lawrence – 2016-09-20T03:09:41.413that would have been my issue, i had assumed that the listen worked with commas, so i wrote
Listen 80,12
, thank you – Jaketr00 – 2016-09-20T03:19:29.363