Replace logrotate conf with templates

This commit is contained in:
Daniel Berteaud 2017-07-12 18:55:21 +02:00
parent 986e7b9ea7
commit 198231fb45
3 changed files with 14 additions and 13 deletions

View File

@ -33,7 +33,8 @@ safe_symlink('/etc/e-smith/templates-default/template-begin-shell', 'root/etc/e-
foreach my $file qw( /etc/sysconfig/php-fpm
/opt/remi/php56/root/etc/sysconfig/php-fpm
/etc/opt/remi/php70/sysconfig/php-fpm
/etc/opt/remi/php71/sysconfig/php-fpm ){
/etc/opt/remi/php71/sysconfig/php-fpm
/etc/logrotate.d/php-fpm ){
templates2events($file, qw(webapps-update bootstrap-console-save));
}

View File

@ -0,0 +1,12 @@
/var/log/php/*/*.log \{
missingok
notifempty
sharedscripts
delaycompress
postrotate
/sbin/e-smith/service php-fpm reload >/dev/null 2>&1 || true
/sbin/e-smith/service php56-php-fpm reload >/dev/null 2>&1 || true
/sbin/e-smith/service php70-php-fpm reload >/dev/null 2>&1 || true
/sbin/e-smith/service php71-php-fpm reload >/dev/null 2>&1 || true
endscript
\}

View File

@ -1,12 +0,0 @@
/var/log/php/*/*.log {
missingok
notifempty
sharedscripts
delaycompress
postrotate
/sbin/e-smith/service php-fpm reload >/dev/null 2>&1 || true
/sbin/e-smith/service php56-php-fpm reload >/dev/null 2>&1 || true
/sbin/e-smith/service php70-php-fpm reload >/dev/null 2>&1 || true
/sbin/e-smith/service php71-php-fpm reload >/dev/null 2>&1 || true
endscript
}