Yet another permissions and ownership question for Apache
I am trying to get the forum on one of my sites to be able to FTP automatically file updates, AutoMOD installs etc. So I installed WU-FTP, and was able to at least let the board system login to the FTP service. From here though is where I think things are getting wonky as sometimes I get random failures from some of the MOD scripts when trying to copy files systematically from an uploaded zip. Those familiar with phpBB likely know the process of installing a MOD, but if someone needs more explanation, let me know…
When I first setup the LAMP stack, the /srv/www/domain.com/public_html/ folders were owned by username:username. Than after following the guide for jailing, over time uploading files and such, I've ended up with a mix of ownerships from username:username, username:filetransfer, username:root, and some even have root:root…
So, my question is, should all of public_html, all folders, files, subdirs and files within, be owned by username:username, given my setup? In my specific case, username is in both of the groups username and filetransfer, with file transfer listed as it's "primary" according to Webmin.
1 Reply
> After issuing these commands, the affected users won't be able to create files in their home directories as these directories will be owned by the root user. You'll want to create a set of directories for each user that they have full access to. Issue the following command for each user, changing the directories created to suit your needs:
cd /home/username
mkdir docs public_html
chown username:username *