From ebeb4e914487fa4b43cacae80db13b6814858336 Mon Sep 17 00:00:00 2001 From: Franco Fichtner Date: Mon, 30 Mar 2020 04:00:16 +0200 Subject: [PATCH] sysutils/consul: sync with upstream Taken from: HardenedBSD --- sysutils/consul/Makefile | 2 +- sysutils/consul/distinfo | 6 +++--- sysutils/consul/files/consul.in | 37 +++++++++++++++++++-------------- 3 files changed, 25 insertions(+), 20 deletions(-) diff --git a/sysutils/consul/Makefile b/sysutils/consul/Makefile index 00aa1bf06df..851faf95e0d 100644 --- a/sysutils/consul/Makefile +++ b/sysutils/consul/Makefile @@ -1,7 +1,7 @@ # $FreeBSD$ PORTNAME= consul -PORTVERSION= 1.6.2 +PORTVERSION= 1.7.2 DISTVERSIONPREFIX= v CATEGORIES= sysutils diff --git a/sysutils/consul/distinfo b/sysutils/consul/distinfo index ae83c204826..6d669cf08db 100644 --- a/sysutils/consul/distinfo +++ b/sysutils/consul/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1576365597 -SHA256 (hashicorp-consul-v1.6.2_GH0.tar.gz) = 98ba4f3e271536954deb118fe88bfcbd3c6150defeee8a2b946a4dff98594a75 -SIZE (hashicorp-consul-v1.6.2_GH0.tar.gz) = 22041280 +TIMESTAMP = 1585133041 +SHA256 (hashicorp-consul-v1.7.2_GH0.tar.gz) = 5fbf25b8df906dfb4133eedf266a5c4a5af3022428b03a41928e1e48bd59a3b9 +SIZE (hashicorp-consul-v1.7.2_GH0.tar.gz) = 22755052 diff --git a/sysutils/consul/files/consul.in b/sysutils/consul/files/consul.in index b9438ffc543..641942aa38e 100644 --- a/sysutils/consul/files/consul.in +++ b/sysutils/consul/files/consul.in @@ -10,18 +10,20 @@ # # Additional variables you can define are: # -# consul_user (string): Set user to run consul. -# Default is "%%CONSUL_USER%%". -# consul_group (string): Set group to run consul. -# Default is "%%CONSUL_GROUP%%". -# consul_pidfile (string): Set full path to pid file -# Default is "/var/run/consul.pid" -# consul_configtest (string): Set to yes to enable Consul config validation -# Set to NO by default -# consul_datadir (dir): Set dir to run consul in. -# Default is "%%CONSUL_DATADIR%%" +# consul_user (string): Set user to run consul. +# Default is "%%CONSUL_USER%%". +# consul_group (string): Set group to run consul. +# Default is "%%CONSUL_GROUP%%". +# consul_pidfile (string): Set full path to pid file +# Default is "/var/run/consul.pid" +# consul_configtest (string): Set to yes to enable Consul config validation +# Set to NO by default +# consul_datadir (dir): Set dir to run consul in. +# Default is "%%CONSUL_DATADIR%%" # consul_syslog_output_enable (bool): Set to YES to enable syslog output # Default is "NO". See daemon(8). +# consul_syslog_output_tag (str): Set syslog tag if syslog enabled. +# Default is "consul". See daemon(8). # consul_syslog_output_priority (str): Set syslog priority if syslog enabled. # Default is "info". See daemon(8). # consul_syslog_output_facility (str): Set to YES to enable syslog output @@ -55,8 +57,11 @@ if [ -n "${consul_dir}" ]; then fi if checkyesno consul_syslog_output_enable; then - consul_syslog_output_flags="-T ${name}" - + if [ -n "${consul_syslog_output_tag}" ]; then + consul_syslog_output_flags="-T ${consul_syslog_output_tag}" + else + consul_syslog_output_flags="-T ${name}" + fi if [ -n "${consul_syslog_output_priority}" ]; then consul_syslog_output_flags="${consul_syslog_output_flags} -s ${consul_syslog_output_priority}" fi @@ -87,14 +92,14 @@ consul_start_precmd() fi if [ ! -d %%ETCDIR%% ]; then - install -d -m 0750 -o ${consul_user} -g ${consul_group} %%ETCDIR%% - fi + install -d -m 0750 -o ${consul_user} -g ${consul_group} %%ETCDIR%% + fi } consul_checkconfig() { - echo "Performing sanity check on ${name} configuration:" - eval ${procname} validate "%%ETCDIR%%" + echo "Performing sanity check on ${name} configuration:" + eval ${procname} validate "%%ETCDIR%%" } run_rc_command "$1"