From 7f331ef9e577a974fe4a242a26fb55f33b7d5938 Mon Sep 17 00:00:00 2001 From: Jack Zampolin Date: Thu, 15 Dec 2016 11:32:12 -0800 Subject: [PATCH] Require user to set .Values.influxURL --- stable/kapacitor/templates/NOTES.txt | 7 +++++++ stable/kapacitor/templates/deployment.yaml | 5 ++++- stable/kapacitor/values.yaml | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/stable/kapacitor/templates/NOTES.txt b/stable/kapacitor/templates/NOTES.txt index dfc2e3d6a7..a6b85c135e 100644 --- a/stable/kapacitor/templates/NOTES.txt +++ b/stable/kapacitor/templates/NOTES.txt @@ -1,3 +1,5 @@ +{{- $bl := empty .Values.influxURL }} +{{- if not $bl }} Kapacitor can be accessed via port 9092 on the following DNS name from within your cluster: - http://{{ template "fullname" . }}.{{ .Release.Namespace }}:9092 @@ -19,4 +21,9 @@ To tail the logs for the Kapacitor pod run the following: To watch for the LoadBalancer IP or Hostname to populate run the following: - kubectl get svc -w --namespace {{ .Release.Namespace }} -l app={{ template "fullname" . }} +{{- end }} +{{- end }} + +{{- if empty .Values.influxURL }} +You have not set .Values.influxURL. Kapacitor needs an InfluxDB instance to create a subscription on. Please set that value to deploy kapacitor {{- end }} \ No newline at end of file diff --git a/stable/kapacitor/templates/deployment.yaml b/stable/kapacitor/templates/deployment.yaml index 57ace19716..abffaaabe7 100644 --- a/stable/kapacitor/templates/deployment.yaml +++ b/stable/kapacitor/templates/deployment.yaml @@ -1,3 +1,5 @@ +{{- $bl := empty .Values.influxURL }} +{{- if not $bl }} apiVersion: extensions/v1beta1 kind: Deployment metadata: @@ -37,4 +39,5 @@ spec: claimName: {{ template "fullname" . }} {{ else }} emptyDir: {} - {{ end }} \ No newline at end of file + {{ end }} +{{- end }} \ No newline at end of file diff --git a/stable/kapacitor/values.yaml b/stable/kapacitor/values.yaml index 39ff0c6cfe..517ab92b15 100644 --- a/stable/kapacitor/values.yaml +++ b/stable/kapacitor/values.yaml @@ -35,4 +35,4 @@ resources: ## Set the URL of InfluxDB instance to create subscription on ## ref: https://docs.influxdata.com/kapacitor/v1.1/introduction/getting_started/ ## -influxURL: http://influxdb-influxdb.tick:8086 +# influxURL: http://influxdb-influxdb.tick:8086