The internet is a bastion of opinion and bullshit. SELinux is a rather difficult bride and as such there is much disinformation regarding how to keep her happy. I have an Apache application that needs to update it’s own cache files and the Fedora installation it was under had the file under the web root with a context of ‘httpd_sys_content_t’. This didn’t work and many of the first suggestions I came across said either disable SELinux or set it to some peculiar context like ‘public_content_rw_t’ and then altering an SELinux boolean to allow such access. We can have no such shenanigans around here, this is how it should be done:
sudo chcon -R -t -P httpd_sys_content_rw_t /var/www/path/to/dir/