wodby/docker4wordpress

Issues with setting up wp-rocket

ad-on-is opened this issue · 1 comments

We are running some wordpress stacks on wodby. When we try to install wp-rocket it doesn't work out of the box, unless we set chmod 777 wp-config.php

How to reproduce

  • Setup a wordpress stack
  • Install wp-rocket plugin
  • wp-rocket complains about missing permissions
  • Reload site
  • wp-rocket not creating cache/wp-rocket/example.com/*
  • Update wp-config.php with define('WP_CACHE', true);
  • Reload site
  • wp-rocket still not creating cache/wp-rocket/example.com/*

What works

  • chmod 777 wp-config.php
  • Install wp-rocket plugin
  • wp-rocket can create cache/wp-rocket/example.com/*

Moved from docker4php.

So basically the issue is www-data user can't write to wp-config.php which isn't an issue at all, giving writing permissions to php-fpm is not secure. Codebase files owned by wodby user, see https://github.com/wodby/php#users-and-permissions for more details