Custom DirectoryIndex for virtual hosts?

I ran across h5ai ( earlier today, and think it’d be kind of neat to set that up as a custom index page for one or two of my virtual hosts. To make that work, though, that vhost needs a custom DirectoryIndex entry–and I’d think that this could be helpful for other folks as well. It seems this would take a config entry for the vhost.

I’m having trouble following the syntax of /etc/e-smith/templates/etc/httpd/conf.d/virtualhosts.conf/20virtual_hosts, which looks like the place where this would be set. Any thoughts on how to modify this?

1 Like

Take a look at


It is the sub template of the templates you pointed, you need to create a prop to display or not your configuration

1 Like

h5ai probably is the most popular one on its category (haven’t used it myself but heard of it many years ago). FYI, there are some other alternatives.

@danb35 this how you can read a prop for a specific vhost

$VhostName is the key name and the name of your vhost


$phpCustomSettings = $vdb->get_prop("$VhostName",'PhpCustomSettings') || 'disabled';
if ($phpCustomSettings eq 'enabled'){
# do something
} else {
 return "# not enabled in this vhost\n";