From c9795a3b746f792cacbe09d46c019606c508b385 Mon Sep 17 00:00:00 2001 From: Thomas Constans Date: Mon, 13 Jan 2025 22:25:45 +0100 Subject: [PATCH] amelioration emplacement des logs et rotation --- templates/logrotate.conf.jj | 4 ++-- templates/www.conf | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/templates/logrotate.conf.jj b/templates/logrotate.conf.jj index 3c64566..d4a92e7 100644 --- a/templates/logrotate.conf.jj +++ b/templates/logrotate.conf.jj @@ -1,11 +1,11 @@ -/var/opt/remi/php{{ php_version_nodot }}/log/php-fpm/*log { +{{ php_fpm_log_dir }}/php_fpm_{{ php_pool_name }}*.log { daily rotate 15 missingok notifempty sharedscripts postrotate - /bin/systemctl reload php{{ php_version_nodot }}-php-fpm + /bin/systemctl reload php{{ php_version }}-php-fpm endscript } diff --git a/templates/www.conf b/templates/www.conf index 9f4bc49..ac877cc 100644 --- a/templates/www.conf +++ b/templates/www.conf @@ -15,8 +15,8 @@ pm.max_requests = {{ php_pm_max_requests }} pm.status_path = {{ php_pm_status_url }} ping.path = /ping access.format = "%R - %u %t \"%m %r%Q%q\" %s %f %{mili}d %{kilo}M %C%%" -access.log = {{ php_fpm_log_dir }}$pool.access.log -slowlog = {{ php_fpm_log_dir }}$pool.slow.log +access.log = {{ php_fpm_log_dir }}php_fpm_$pool.access.log +slowlog = {{ php_fpm_log_dir }}php_fpm_$pool.slow.log request_slowlog_timeout = 5s php_value[session.save_handler] = files php_value[session.save_path] = {{ php_fpm_lib_dir }}/sessions