Hello,
I'm trying to use the built-in httpd server that ships with NetBSD, and I'm trying to get virtual hosts working and it doesn't seem to want to work. I've followed the man page and put the line in the EXAMPLES
section regarding virtual hosting in inetd.conf
, but no luck.
`
To configure set of virtual hosts, one would use an inetd.conf(5) entry
like:
http stream tcp nowait:600 _httpd /usr/libexec/httpd httpd -v /var/vroot /var/www
and inside /var/vroot create a directory (or a symlink to a directory)
with the same name as the virtual host, for each virtual host. Lookups
for these names are done in a case-insensitive manner, and may include
the port number part of the request, allowing for distinct virtual hosts
on the same name.
`
in my vroot
I've tried a combination of domain names, like example.com
, just example
or even the full www.example.com
, each with an index.html
file in them, but i always get a 404.
It's only if I were to type in the browsers URL example.com/example.com
, will it go to the example.com
directory and display the index html file there, but that doesn't seem to follow the behavior that is laid out in the man page.