Skip to content

Commit

Permalink
Fix prometheus scrape annotations (#156)
Browse files Browse the repository at this point in the history
Signed-off-by: Tamal Saha <tamal@appscode.com>
  • Loading branch information
tamalsaha committed Dec 27, 2018
1 parent 6d8e444 commit bd30a17
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions chart/vault-operator/templates/service.yaml
Expand Up @@ -10,10 +10,10 @@ metadata:
heritage: "{{ .Release.Service }}"
{{- if and (eq .Values.monitoring.agent "prometheus.io/builtin") .Values.monitoring.operator }}
annotations:
prometheus.io/scrap: "true"
prometheus.io/operator_path: "/metrics"
prometheus.io/operator_port: "8443"
prometheus.io/operator_scheme: "https"
prometheus.io/scrape: "true"
prometheus.io/path: "/metrics"
prometheus.io/port: "8443"
prometheus.io/scheme: "https"
{{- end }}
spec:
ports:
Expand Down
10 changes: 5 additions & 5 deletions hack/deploy/install.sh
Expand Up @@ -512,11 +512,11 @@ fi
if [ "$MONITOR_OPERATOR" = "true" ] && [ "$MONITORING_AGENT" != "$MONITORING_AGENT_NONE" ]; then
case "$MONITORING_AGENT" in
"$MONITORING_AGENT_BUILTIN")
kubectl annotate service vault-operator -n "$VAULT_OPERATOR_NAMESPACE" --overwrite \
prometheus.io/scrap="true" \
prometheus.io/operator_path="/metrics" \
prometheus.io/operator_port="8443" \
prometheus.io/operator_scheme="https"
kubectl annotate service vault-operator -n "$VAULT_OPERATOR_NAMESPACE" --overwrite \
prometheus.io/scrape="true" \
prometheus.io/path="/metrics" \
prometheus.io/port="8443" \
prometheus.io/scheme="https"
;;
"$MONITORING_AGENT_COREOS_OPERATOR")
${SCRIPT_LOCATION}hack/deploy/monitor/servicemonitor-operator.yaml | $ONESSL envsubst | kubectl apply -f -
Expand Down

0 comments on commit bd30a17

Please sign in to comment.