How to change the home dir of sub-servers

Hi,

A customer of us who uses Virtualmin Pro 3.78 and is migrating a lot (about 300) of sites from a old server to this new server.

Because a lot of sites uses hard-coded references, I changed a lot of paths in the server templates for Apache. This is working as a charm, except for sub-servers. When the user creates a sub-server (so that the customer of the site has only one login for all his domains) the customer wants the following layout:

/home/eeterweb/eeterijdedungensebrug.nl (virtual server). /home/eeterweb/graadmeter.com (sub-server site)

I looked everywhere in Virtualmin and on the forums. Can you help me out?

Thanks,

Justin.

Status: 
Closed (fixed)

Comments

Unfortunately, there is no way currently to configure Virtualmin to use this kind of scheme.

The closest you can get is to put each domain's directory at /home/username/domains/maindomain.com , /home/username/domains/anotherdomain.com . Would that work for you?

Hi Jamie,

Thanks for the reply, we will do it with symlinks, that should work to.

Another question, the customer wants to be able to go to www.domain.tld/awstats to view the awstats statistics. Per default it is only possible if you type /awstats.pl after the URL. We can change it after the creation of the virtual server, but with 300+ sites it is not the most ideal situation.

Can I change and use the Apache server template for this or will that be a problem with the awstats configuration that Virtualmin does when creating a virtual server.

Thanks again.

Justin.

You could add an Apache redirect from /awstats to awstats.pl in the default template, in the Apache Webserver section. This would avoid having to add it to each virtual server separately..

Hi Jamie,

Thanks, it worked out for us by adding
RewriteRule ^/awstats$ /cgi-bin/awstats.pl [R,L]
RewriteRule ^/awstats/$ /cgi-bin/awstats.pl [R,L]

in the httpd.conf file.

Automatically closed -- issue fixed for 2 weeks with no activity.