diff --git a/charts/fluentd/Chart.yaml b/charts/fluentd/Chart.yaml
index 99fafe16..cb748397 100644
--- a/charts/fluentd/Chart.yaml
+++ b/charts/fluentd/Chart.yaml
@@ -2,7 +2,7 @@ apiVersion: v2
name: fluentd
description: A Helm chart for Kubernetes
# type: application
-version: 0.5.0
+version: 0.5.1
appVersion: v1.16.2
icon: https://www.fluentd.org/images/miscellany/fluentd-logo_2x.png
home: https://www.fluentd.org/
diff --git a/charts/fluentd/templates/tests/test-connection.yaml b/charts/fluentd/templates/tests/test-connection.yaml
index 7c0f8150..2b07ec4f 100644
--- a/charts/fluentd/templates/tests/test-connection.yaml
+++ b/charts/fluentd/templates/tests/test-connection.yaml
@@ -1,3 +1,10 @@
+{{/*
+Target the very simple case where
+fluentd is deployed with the default values
+If the fluentd config is overriden and the metrics server removed
+this will fail.
+*/}}
+{{ if empty .Values.service.ports }}
apiVersion: v1
kind: Pod
metadata:
@@ -10,6 +17,13 @@ spec:
containers:
- name: wget
image: busybox
- command: ['wget']
- args: ['{{ include "fluentd.fullname" . }}:{{ .Values.service.port }}']
+ command:
+ - sh
+ - -c
+ - |
+ set -e
+ # Give fluentd some time to start up
+ while :; do nc -vz {{ include "fluentd.fullname" . }}:24231 && break; sleep 1; done
+ wget '{{ include "fluentd.fullname" . }}:24231/metrics'
restartPolicy: Never
+{{ end }}
\ No newline at end of file
diff --git a/charts/fluentd/values.yaml b/charts/fluentd/values.yaml
index 59a66531..ac05f8b2 100644
--- a/charts/fluentd/values.yaml
+++ b/charts/fluentd/values.yaml
@@ -318,6 +318,14 @@ fileConfigs:
emit_unmatched_lines true
+ # expose metrics in prometheus format
+
+
02_filters.conf: |-