Search code examples
phplinuxcentosfuelphp

Linux - Centos : Giving nginx chmod access


Alright so I cannot for the life of me get rid of this error :

Warning!

ErrorException [ Warning ]: chmod(): Operation not permitted

COREPATH/classes/finder.php @ line 511:

510:    {
511:    chmod($dir.$file, \Config::get('file.chmod.files', 0666));
512:    }

Here is my setup for permissions :

(775) : drwxrwxr-x myuser:nginx

Groups :

nginx:x:499:myuser,nginx

PHP-FPM Config

user = nginx
group = nginx

So this works for creating / editing files ect. and that all works fine.

How can I get this to work correctly?


Solution

  • It was because nginx had created a file, it has to be the owner.