How to _NOT_ create the default directory structure (/home/usrname) for newly added domains.

I have setup a server template that keeps the home directory for some domains shared. (Useful for a multi-site CMS setup) While modifying the Apache Website directives I was successfully able to do that, Virtualmin still creates the default user Home Directory (/home/username). Since these directories are redundant for such shared domains. Is there a way by which I can avoid creating them altogether?

Thanks

-jayesh

Status: 
Closed (fixed)

Comments

This may be possible .. what features do you have enabled for these domains though?

Also, you might want to consider creating alias virtual servers that point to your multi-site CMS. Aliases don't need to have a home directory, they just have a DNS domain and an entry in the target's Apache config so that it accepts requests for the alias domain too.

Minimal Features - - MySQL Database/User - Webalizer Reporting / Log file rotation - Apache Website (defaulting to the common path) And - No Email handling - No BIND DNS

Alias virtual servers might be a solution, but they don't allow stats. (or do they?)

Thanks,

-jayesh

Yeah, you can't have a database in an alias domain, nor separate webalizer reporting.

Another option is to create a sub-server which uses the top-level server's web directory, and so can share a single CMS install. This thread discusses doing that with Drupal : https://www.virtualmin.com/node/9813

Thanks JamieCameron,

The shared folder option for virtual servers is already resolved, but since I need the MySQL Database and Statistics working I would keep the domains as Top-level virtual servers and 'live' with the redundant directories created -- just because this allows a flexiblity that Sub-level servers might limit.

Again, all I wanted was not to create a user when creating the virtual server (and have only the Apache Website -- shared root i.e. and a MySQL database created). I have also disabled creating the Webmin Login, but that still does not stop the user being created.

Thanks for replying, -jayesh

Yeah, a user is needed in order to own the home directory.

Sub-servers are better in that they don't have a user or a Webmin login, but can have everything else a top-level serve can. So maybe that is the best way to go?