incubator-pagespeed-mod icon indicating copy to clipboard operation
incubator-pagespeed-mod copied to clipboard

Doesn't work with SELinux in enforcing mode

Open arundaskd opened this issue 6 years ago • 2 comments

When SELinux is in enforcing mode, I get the following errors and some filters not working. [pagespeed:error] [pid 3969:tid 139713255986944] [mod_pagespeed 1.13.35.2-0 @3969] Failed to mkdir /var/cache/mod_pagespeed/ flush /bUBvUZ_Wi_svXCmxK86L.outputlock: No such file or directory

Tried the following, semanage fcontext -a -t httpd_sys_rw_content_t "/var/cache/mod_pagespeed(/.*)?" and semanage fcontext -a -t httpd_cache_t "/var/cache/mod_pagespeed(/.*)?" restorecon -Rv /var/cache/mod_pagespeed/

arundaskd avatar Jan 31 '19 03:01 arundaskd

@arundaskd Did you ever find a solution to this? I'm having the exact same issue.

ethauvin avatar May 22 '19 18:05 ethauvin

It works here on Fedora with standard selinux attributes as follows:

semanage fcontext -l | grep /var/cache/mod_
/var/cache/mod_.*                                  all files          system_u:object_r:httpd_cache_t:s0 
/var/cache/mod_gnutls(/.*)?                        all files          system_u:object_r:httpd_cache_t:s0 
/var/cache/mod_proxy(/.*)?                         all files          system_u:object_r:httpd_cache_t:s0 
/var/cache/mod_ssl(/.*)?                           all files          system_u:object_r:httpd_cache_t:s0

felfert avatar Jul 02 '19 07:07 felfert