Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 Apr 2016 01:14:50 +0000 (UTC)
From:      Ganbold Tsagaankhuu <ganbold@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r413091 - in head/lang/php56: . files
Message-ID:  <201604120114.u3C1EonL075626@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ganbold (src,doc committer)
Date: Tue Apr 12 01:14:49 2016
New Revision: 413091
URL: https://svnweb.freebsd.org/changeset/ports/413091

Log:
  Add configtest support for php-fpm rc script.
  
  PR:	208324
  Sponsored by:	A-Team Systems

Modified:
  head/lang/php56/Makefile
  head/lang/php56/files/php-fpm.in

Modified: head/lang/php56/Makefile
==============================================================================
--- head/lang/php56/Makefile	Mon Apr 11 23:36:34 2016	(r413090)
+++ head/lang/php56/Makefile	Tue Apr 12 01:14:49 2016	(r413091)
@@ -3,7 +3,7 @@
 
 PORTNAME=	php56
 PORTVERSION=	5.6.20
-PORTREVISION?=	0
+PORTREVISION=	1
 CATEGORIES?=	lang devel www
 MASTER_SITES=	PHP/distributions
 DISTNAME=	php-${PORTVERSION}

Modified: head/lang/php56/files/php-fpm.in
==============================================================================
--- head/lang/php56/files/php-fpm.in	Mon Apr 11 23:36:34 2016	(r413090)
+++ head/lang/php56/files/php-fpm.in	Tue Apr 12 01:14:49 2016	(r413091)
@@ -17,11 +17,16 @@
 name="php_fpm"
 rcvar=php_fpm_enable
 
+start_precmd="php_fpm_checkconfig"
+restart_precmd="php_fpm_checkconfig"
+reload_precmd="php_fpm_checkconfig"
+configtest_cmd="php_fpm_checkconfig"
+
 load_rc_config "$name"
 
 : ${php_fpm_enable="NO"}
 
-extra_commands="reload logrotate"
+extra_commands="reload configtest logrotate"
 
 command="%%PREFIX%%/sbin/php-fpm"
 pidfile="/var/run/php-fpm.pid"
@@ -40,4 +45,10 @@ php_fpm_logrotate() {
         kill -USR1 $rc_pid
 }
 
+php_fpm_checkconfig()
+{
+        echo "Performing sanity check on php-fpm configuration:"
+        eval ${command} -t
+}
+
 run_rc_command "$1"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201604120114.u3C1EonL075626>