vhosts.d/*.conf
Your virtual host conguration should be located here. The directory contains
template les for virtual hosts with and without SSL. Every le in this directory
ending with .conf is automatically included in the Apache conguration. Refer
to Section 20.2.2.1, “Virtual Host Conguration” (page 365) for details.
20.2.2 Conguring Apache Manually
Conguring Apache manually involves editing plain text conguration les as user
root.
20.2.2.1 Virtual Host Conguration
The term virtual host refers to Apache's ability to serve multiple universal resource
identiers (URIs) from the same physical machine. This means that several domains,
such as www.example.com and www.example.net, are run by a single Web server on
one physical machine.
It is common practice to use virtual hosts to save administrative effort (only a single
Web server needs to be maintained) and hardware expenses (each domain does not re-
quire a dedicated server). Virtual hosts can be name based, IP based, or port based.
To list all existing virtual hosts, use the command httpd2 -S. This outputs a list
showing the default server and all virtual hosts together with their IP addresses and
listening ports. Furthermore, the list also contains an entry for each virtual host showing
its location in the conguration les.
Virtual hosts can be congured via YaST as described in Section “Virtual
Hosts” (page 373) or by manually editing a conguration le. By default, Apache in
openSUSE is prepared for one conguration le per virtual host in /etc/apache2/
vhosts.d/. All les in this directory with the extension .conf are automatically
included to the conguration. A basic template for a virtual host is provided in this di-
rectory (vhost.template or vhost-ssl.template for a virtual host with SSL
support).
The Apache HTTP Server 365