we have a few users that upload directly to the server. Now we want to implement a new system where we use a common PC for all uploads. We already created separate user accounts for all users in that PC, and created SSH key based login to the server. So now, users can login via ssh/sftp to their respective user accounts in main PC and then do all the uploading to the server. Now the problem is, we want to give full access to only 2 users, and restrict all other users from accessing anything other than /var/www/html.
Create a group for the users how should have full acces:
$ sudo groupadd full_access $ sudo chown -R :full_access /path/to/special/data/ $ sudo usermod -a -G full_access username
Don't do something like "sudo chown -R :www_full_access /"! This will break your system. If you need user with root-access to your system, add them to the sudoers group:
$ sudo usermod -a -G sudo username