Adding files with sFTP to /etc/shared/nginx/html changes group to myname:myname
After creating a LEMP on Ubuntu droplet, I added two users to the sudo group, to give my colleague (hisname) and I (myname) admin rights on the droplet. After this, I changed the ownership of the /etc/shared/nginx/html folder to myname:sudo and set the permissions to 775.
sudo chown -R myname:sudo /etc/shared/nginx/html sudo chmod -R 775 /etc/shared/nginx/html
The idea behind this is that multiple people should be able to change the production website. So, as long as they were part of the sudo group, they would be able to change the website.
However, when my colleague connects to the droplet with sFTP (client: Transmit), and adds the appropriate website files, all ownership and permissions are changed to hisname:hisname. This means that I can't alter any of those files.
We're not sure whether this is something that is configured in the sFTP client, or on the droplet itself. Does anyone know how I can make sure that files changed/added by the sFTP client are set to user:sudo with 775?