How to automatically create a custom directory for new virtual servers?

Hello guys

How can I configure Virtualmin to automatically create a custom directory inside the home folder whenever I create a new virtual server?

For example I create, then the home directory is /home/test/ - and then I want a custom folder there, for example /home/test/custom

What’s the best way to configure so?

Thanks for your help


Anything in the directory /etc/skel will be copied into any new Virtual Server’s that are created.

So in your case, you can just create a dir “/etc/skel/custom”.


An alternative, should Eric’s good suggestion not work for some reason, is to use a post-server-creation script which you can set in the Virtual Configuration, section “Actions upon server and user creation”. You’ll find documentation about those scripts there too.