From a9c1bc3518750e25d23ec19e592750a8f744e696 Mon Sep 17 00:00:00 2001 From: Michele Baldessari Date: Wed, 9 May 2018 16:17:50 +0200 Subject: [PATCH] Lower the default stunnel log level Right now the default stunnel.conf log level is set at 'notice' which, when we deploy redis, fills up the logs with the following messages: May 09 14:18:36 controller-1.redhat.local dockerd-current[19810]: 2018.05.09 14:18:36 LOG5[1:139972682520320]: connect_blocking: connected 127.0.0.1:6379 May 09 14:18:36 controller-1.redhat.local dockerd-current[19810]: 2018.05.09 14:18:36 LOG5[1:139972682520320]: Service [redis] connected remote server from 127.0.0.1:60412 May 09 14:18:36 controller-1.redhat.local stunnel[41495]: LOG5[1:139972682409728]: Service [redis] accepted connection from 172.17.1.21:60770 May 09 14:18:36 controller-1.redhat.local dockerd-current[19810]: 2018.05.09 14:18:36 LOG5[1:139972682409728]: Service [redis] accepted connection from 172.17.1.21:60770 May 09 14:18:36 controller-1.redhat.local stunnel[41495]: LOG5[1:139972682409728]: connect_blocking: connected 127.0.0.1:6379 May 09 14:18:36 controller-1.redhat.local dockerd-current[19810]: 2018.05.09 14:18:36 LOG5[1:139972682409728]: connect_blocking: connected 127.0.0.1:6379 May 09 14:18:36 controller-1.redhat.local stunnel[41495]: LOG5[1:139972682409728]: Service [redis] connected remote server from 127.0.0.1:60418 May 09 14:18:36 controller-1.redhat.local dockerd-current[19810]: 2018.05.09 14:18:36 LOG5[1:139972682409728]: Service [redis] connected remote server from 127.0.0.1:60418 Those messages are from the haproxy healthceck. Let's move the default debug config to warning which will ignore the above errors. Closes-Bug: #1770180 Change-Id: I93bd0048e85864fa9e62dc38c3575ec7b48e5df5 --- manifests/stunnel.pp | 5 +++++ templates/stunnel/foreground.erb | 1 + 2 files changed, 6 insertions(+) diff --git a/manifests/stunnel.pp b/manifests/stunnel.pp index 25b2ff483..b2c56ec1d 100644 --- a/manifests/stunnel.pp +++ b/manifests/stunnel.pp @@ -31,10 +31,15 @@ # container. # Defaults to 'no' # +# [*debug*] +# (Optional) Sets the debug level in stunnel.conf +# Defaults to '4' which translates to 'warning'. +# class tripleo::stunnel ( $manage_service = true, $service_ensure = 'running', $foreground = 'no', + $debug = 'warning', ){ package { 'stunnel': ensure => 'present' diff --git a/templates/stunnel/foreground.erb b/templates/stunnel/foreground.erb index 2ceff96f5..8b09f4c4d 100644 --- a/templates/stunnel/foreground.erb +++ b/templates/stunnel/foreground.erb @@ -1 +1,2 @@ foreground = <%= @foreground %> +debug = <%= @debug %>