I'm using docker for setting up a nginx and php-fpm server. And I have the next problem, when I have an error in php nginx does not log the error anywhere.

I have this in my project conf.


error_log /LOGS/simple_error.log debug;
access_log /LOGS/custom_access.log;

Inside the access file, I can see this lanes. That means I have a 500 status error, and I cannot see why.

Both of project error log, nginx error log are completely empty and I cannot see why. - - [05/Apr/2019:11:51:31 +0000] "POST /user/create/ HTTP/1.1" 500 5 "-" "PostmanRuntime/7.6.1" - - [05/Apr/2019:11:52:20 +0000] "POST /user/create/ HTTP/1.1" 200 58 "-" "PostmanRuntime/7.6.1"

I added this in the www.conf inside php configuration folder, and I still don't have error log from php.


php_flag[display_errors] = on
php_admin_value[error_log] = /var/log/fpm-php.www.log
php_admin_flag[log_errors] = on

Inside /var/log/ directory there are two directories but there is not php-fpm log I'm looking for`.

Thanks in advance.

0 Answers