How to auto chown/chgrp files after created an user or FTP upload?

DavidLux

Member
Joined
Nov 6, 2012
Messages
160
Points
18
How to auto chown/chgrp files after created an user or FTP upload in a VPS? I have to do it manually every time I created a new account on my vps hosting to edit/delete files or folders.

Here's my codes

Code:
chown username:username public_html -R
is there a way to do this automatically?
 

RDO Servers

New member
Joined
Apr 3, 2015
Messages
770
Points
0
You could SetGUID the permissions for the folder.

SetGID, however, is a whole different ball game. When a directory has the SetGID bit set and a file is created within that directory the group ownership of the file is automatically modified to be the group of the directory.
- quote from, and more info at [URLnofo]http://blog.superuser.com/2011/04/22/linux-permissions-demystified/[/URLnofo]
 
Latest threads
Replies
0
Views
29
Replies
0
Views
31
Replies
1
Views
41
Replies
3
Views
105
Recommended threads
Top