Re: port 80 + 8080 + SSL (443)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 16.02.09 08:22, KURT PETERS wrote:
> I would like to set up my server to respond with the same website for
> incoming requests to both port 80 and 8080, but a different virtual server
> for 443. I set up something like below, but it seems like overkill.

> Listen 80
> Listen 8080
> Listen 443
> 
> NameVirtualHost 172.20.30.40:80
> NameVirtualHost 172.20.30.40:8080
> NameVirtualHost 192.168.1.40:80
> NameVirtualHost 192.168.1.40:8080
> 
> <VirtualHost 172.20.30.40:80 172.20.30.40:8080 192.168.1.40:80 192.168.1.40:8080>
> ServerName www.example.com
> 
> ServerAlias LOCALNAME
> DocumentRoot /var/www
> </VirtualHost>
> 
> NameVirtualHost 172.20.30.40:443
> NameVirtualHost 192.168.1.40:443
> 
> <VirtualHost 172.20.30.40:443 192.168.1.40:443>
> ServerName www.example.com
> DocumentRoot /var/secwww
> </VirtualHost>

That should work.

> Is there an "easier" way to do this?  Also, is this right?  I do get a
> warning that Apache2 cannot determine the servername, and I'm not sure
> what to do to get rid of that error.

I don't think there is any easier way, not this is an overkill.
The servername error message is apparently related to different vhost...
or the main server if you don't have ServerName in main config.

> On a similar, but equally important note:

> I did something like above, but I get a timeout for incoming to https://
> when I'm testing it from outside my router.  Any hints at what might be
> going wrong there?

port 443 is firewalled or not NAT'ed from outside

-- 
Matus UHLAR - fantomas, uhlar@xxxxxxxxxxx ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
The 3 biggets disasters: Hiroshima 45, Tschernobyl 86, Windows 95

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux