Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 8 Oct 2016 13:36:14 +0000 (UTC)
From:      Bernard Spil <brnrd@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r423507 - head/security/acme-client/files
Message-ID:  <201610081336.u98DaE3R087747@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: brnrd
Date: Sat Oct  8 13:36:14 2016
New Revision: 423507
URL: https://svnweb.freebsd.org/changeset/ports/423507

Log:
  security/acme-client: Fixes for periodic script
  
    - Fix domains and client-args variable typos [1]
    - Don't display deploy messages when deploy-script unset[2]
  
  PR:		213162 [1], 213163 [2]
  Submitted by:	peterj

Modified:
  head/security/acme-client/files/000.acme-client.sh.in

Modified: head/security/acme-client/files/000.acme-client.sh.in
==============================================================================
--- head/security/acme-client/files/000.acme-client.sh.in	Sat Oct  8 13:12:31 2016	(r423506)
+++ head/security/acme-client/files/000.acme-client.sh.in	Sat Oct  8 13:36:14 2016	(r423507)
@@ -32,27 +32,27 @@ case "$weekly_acme_client_enable" in
 	echo
 	echo "Checking Let's Encrypt certificate status:"
 
-        : ${weekly_acme_client_args:="-b"}
-
 	if [ -x "$weekly_acme_client_renewscript" ] ; then
 		$weekly_acme_client_renewscript
 	else
+		: ${weekly_acme_client_args:="-b"}
 		if [ -z "$weekly_acme_client_domains" ] ; then
-			weekly_acme-client_domains=$(hostname -f)
+			weekly_acme_client_domains=$(hostname -f)
 			echo "Using hostname: $weekly_acme_client_domains"
 		fi
 		if [ -n "$weekly_acme_client_challengedir" ] ; then
-			weekly_acme-client_args="$weekly_acme_client_args -C $weekly_acme_client_challengedir"
+			weekly_acme_client_args="$weekly_acme_client_args -C $weekly_acme_client_challengedir"
 		fi
 		%%LOCALBASE%%/bin/acme-client $weekly_acme_client_args $weekly_acme_client_domains
 	fi
 
-	echo "Deploying Let's Encrypt certificates:"
-
-	if [ -x "$weekly_acme_client_deployscript" ] ; then
-		$weekly_acme_client_deployscript
-	else
-		echo 'Skipped, deploy script not set.'
+	if [ -n "$weekly_acme_client_deployscript" ] ; then
+		if [ -x "$weekly_acme_client_deployscript" ] ; then
+			echo "Deploying Let's Encrypt certificates:"
+			$weekly_acme_client_deployscript
+		else
+			echo 'Skipped, deploy script does not exist or is not executable'
+		fi
 	fi
         ;;
     *)



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