diff --git a/charts/templates/servicemonitor.yaml b/charts/templates/servicemonitor.yaml index 1055c37..386d051 100644 --- a/charts/templates/servicemonitor.yaml +++ b/charts/templates/servicemonitor.yaml @@ -1,3 +1,4 @@ +{{- if .Values.monitoring.enabled -}} apiVersion: monitoring.coreos.com/v1 kind: ServiceMonitor metadata: @@ -9,4 +10,5 @@ spec: port: metrics jobLabel: app.kubernetes.io/name selector: - matchLabels: {{ include "coral-credits.selectorLabels" . | nindent 6 }} \ No newline at end of file + matchLabels: {{ include "coral-credits.selectorLabels" . | nindent 6 }} +{{- end }} \ No newline at end of file diff --git a/tools/functional_test.sh b/tools/functional_test.sh index 8c2a156..ae9480b 100755 --- a/tools/functional_test.sh +++ b/tools/functional_test.sh @@ -79,7 +79,8 @@ helm upgrade $RELEASE_NAME ./charts \ --set-string image.tag=${GITHUB_SHA::7} \ --set settings.superuserPassword=$TEST_PASSWORD \ --set ingress.host=$SITE \ - --set ingress.tls.enabled=false + --set ingress.tls.enabled=false \ + --set monitoring.enabled=false # Wait for rollout kubectl rollout status deployment/$RELEASE_NAME -n $NAMESPACE --timeout=300s -w