]> git.pld-linux.org Git - packages/php.git/commitdiff
fix fpm logs. no longer conflict with 5.4 and use existing paths
authorElan Ruusamäe <glen@delfi.ee>
Mon, 8 Oct 2012 08:07:26 +0000 (11:07 +0300)
committerElan Ruusamäe <glen@delfi.ee>
Wed, 10 Oct 2012 09:05:31 +0000 (12:05 +0300)
Conflicts:
php-fpm-config.patch
php.spec

php-fpm-config.patch
php-fpm.logrotate
php.spec

index 34948a1f367f93aa001eb4bd5c3692bd04adec6c..fdd328093ced4ba426102f24f8cf98ada08b57de 100644 (file)
@@ -1,6 +1,6 @@
---- php-5.3.14/sapi/fpm/php-fpm.conf.in~       2012-06-13 11:18:44.000000000 +0300
-+++ php-5.3.14/sapi/fpm/php-fpm.conf.in        2012-07-12 15:38:49.056368781 +0300
-@@ -22,7 +22,7 @@
+--- php-5.3.17/sapi/fpm/php-fpm.conf.in~       2012-09-13 00:27:16.000000000 +0300
++++ php-5.3.17/sapi/fpm/php-fpm.conf.in        2012-10-09 20:00:31.645362454 +0300
+@@ -22,14 +22,14 @@
  ; Pid file
  ; Note: the default prefix is @EXPANDED_LOCALSTATEDIR@
  ; Default Value: none
@@ -9,7 +9,15 @@
  
  ; Error log file
  ; If it's set to "syslog", log is sent to syslogd instead of being written
-@@ -140,7 +140,7 @@
+ ; in a local file.
+ ; Note: the default prefix is @EXPANDED_LOCALSTATEDIR@
+ ; Default Value: log/php-fpm.log
+-;error_log = log/php-fpm.log
++error_log = log/@processname@.log
+ ; syslog_facility is used to specify what type of program is logging the
+ ; message. This lets syslogd specify that messages from different facilities
+@@ -148,7 +148,7 @@
  ;                            specific port;
  ;   '/path/to/unix/socket' - to listen on a unix socket.
  ; Note: This value is mandatory.
index 3bec7c1a11e7ba613b5ee84c267fc667c5a03dc8..694b2312606e0056fdc7b6b7ece568f88d6069f1 100644 (file)
@@ -1,11 +1,10 @@
-/var/log/fpm.log
-/var/log/fpm-slow.log
+/var/log/@processname@.log
 {
        notifempty
        missingok
        create 600 root root
        sharedscripts
        postrotate
-               /sbin/service php-fpm flush-logs > /dev/null
+               /sbin/service @processname@ flush-logs > /dev/null
        endscript
 }
index af2e047c418b62c68b4e852b3792c509ae9e3a7d..03000875ea73015b70891ead41fe01cb6120aea4 100644 (file)
--- a/php.spec
+++ b/php.spec
@@ -2425,13 +2425,14 @@ cp -p sapi/fpm/php-fpm.conf $RPM_BUILD_ROOT%{_sysconfdir}
 cp -p sapi/fpm/status.html $RPM_BUILD_ROOT%{_datadir}/fpm
 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
 install -p %{SOURCE10} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-fpm
+install -d $RPM_BUILD_ROOT/etc/logrotate.d
+cp -p %{SOURCE11} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}-fpm
+
 %{__sed} -i -e '
        s#/usr/lib/php#%{php_extensiondir}#
        s#/etc/php#%{_sysconfdir}#
        s#@processname@#%{name}-fpm#g
-' $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}-fpm $RPM_BUILD_ROOT%{_sysconfdir}/php-fpm.conf
-install -d $RPM_BUILD_ROOT/etc/logrotate.d
-cp -p %{SOURCE11} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}-fpm
+' $RPM_BUILD_ROOT{/etc/{rc.d/init.d/%{name}-fpm,logrotate.d/%{name}-fpm},%{_sysconfdir}/php-fpm.conf}
 %endif
 
 # install Embedded API
This page took 0.080022 seconds and 4 git commands to generate.