2

I have set up a Wordpress Server for my developers and it is working. However now when we copy over files to the /usr/share/nginx/html folder I am having permissions issues. I will try explain this as easy as I can.

Here are the permissions on the folder:

drwxrwsr-x+ 9 nginx wpress 4096 Jun 16 08:41 html

As you can see the owner is 'nginx' and group is 'wpress'. I did set up a ACL on this folder for a remote developer but that is not an issue.

My problem is that when my developer copies over files to this folder --> /usr/share/nginx/html it will not inherit the owner nginx. It will look similar to this:

-rw-r--r-- 1 pbrod wpress 0 Jun 16 08:14 file1

How I would want it to look is as follows:

-rw-r--r-- 1 nginx wpress 0 Jun 16 08:14 file1

I want the files that are copied in or created to inherit the owner and group. When I set up the permissions I did a 2775 on the folder so it would inherit group ownership. The problem is that I need files created or copied into this folder to inherit the owner, which is nginx.

I am thinking I can do this via SETFACL but not 100% sure how to do it as anything I tried does not seem to work.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.