I,
I am going to ask a question that has already been posted many times but even though I have read many guides and posts, I still have doubts.
I have a server with ubuntu 14.04 on which I have a user with sudo permissions (secondary group "sudo") and a user who just want to use for the "web server".
I explain in detail...
-
My webserver user is "jack" and this is part of the group www-data (as the primary group)
-
The virtual hosts point to the jack's home directory where I created a subfolder called "alias" which contains subfolders with the various sub-domains
es.
/home/jack/public_html <-- main site
/home/jack/alias/forum <-- subdomain
/home/jack/alias/wiki <-- subdomain
/home/jack/alias/cloud <-- subdomain
what I would like to know is:
-first question-
is correct that jack belongs to the primary group www-data instead of belonging to the group users, and as a secondary group www-data ?
-second question-
a friend advised me to set the permissions on the web server folder in this way
chgrp www-data /home/jack/public_html
chmod g+rwxs /home/jack/public_html
and the same for the alias folders. Now it seems to work but there is a problem....
-if i load a file in the web server root permits are
jack:www-data 0644
-if the files are generated by www-data (for example through a cms)
www-data:www-data 0666
Now, if I edit a file manually, for example via ftp, this changes the permissions and creates problems to the various "web app"
how can I do to fix it?
Thanks for reading Regards, Fabio
Recent Questions...
ما را در سایت Recent Questions دنبال میکنید
برچسب:
نویسنده: استخدام کار
بازدید: 267
تاريخ: دوشنبه
4 مرداد
1395 ساعت: 14:45