Per customer request we needed to configure one of Virtualmin servers to create virtual servers in "Apache mod_php (run as Apache's user)" mode instead of default "FCGId (run as domain owner)", however we are seeing two major issues:
(1) Even if Virtualmin is configured to create virtual servers in "Apache mod_php (run as Apache's user)" mode, all the files and directories in document root belong to the website username group like username:username, whereas we expected them to be created with the following ownership:
username:apache (on RHEL/CentOS)
(2) After running "chgrp -R apache /home/username/public_html" validating the virtual server gives:
Home directory : Sub-directory public_html under home directory is owned by group apache instead of username
How can we properly set Virtualmin so that all the files and directories belong to Apache group and Virtualmin validation not to complain about it?