Code: Select all
/etc/redhat-release: CentOS Linux release 7.6.1810 (Core)
uname: 3.10.0-957.1.3.el7.x86_64 #1 SMP Thu Nov 29 14:49:43 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
httpd -v: Server version: Apache/2.4.6 (CentOS), Server built: Nov 5 2018 01:47:09
We're not a giant ISP (this is a corporate server for about 15 different radio station Websites), so I know this can be done. Each /home directory (ex., /home/station1.com, /home/station2.com, etc.) may have a different maintainer. Joe might maintain station1, Tom might maintain station2, and so on. Joe logs in as "joe" and Tom logs in as "tom." All maintainers are members of the "apache" group, and that is their primary group.
The problem is, as changes are made, as people upload pages, and so on, the permissions get reset to owner-write-only. This shows up to our non-technical users as, they're in WordPress Control Panel and are unable to delete or update a plugin. I scan the logs, it shows permission errors, I run ...
Code: Select all
chown -r station_name:apache /public_html/wp-content/
chmod -R g+rw /public_html/wp-content/
I did some research a few months ago and figured out how to set the umask for Apache. That seems to be working: a test PHP script creates a file and it has owner and group rw set.
This has to be something simple. Maybe are users are using an FTP client to do uploads that insists on owner-write permissions? What could I look at? I really, REALLY don't want to do the cheezy, risky klong of just making the "wp-content" folder world-writable. I also want different maintainers to log in under their names. I don't want one master password and a single "master editing" user.
Thanks in advance for any suggestions.