Skip to content

Commit

Permalink
fix annotation bug. Use active service on ingress when ha
Browse files Browse the repository at this point in the history
  • Loading branch information
georgekaz committed Apr 21, 2020
1 parent 1be2446 commit 6e11e40
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
3 changes: 3 additions & 0 deletions templates/server-ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
{{- if ne .mode "external" }}
{{- if .Values.server.ingress.enabled -}}
{{- $serviceName := include "vault.fullname" . -}}
{{- if and (eq .mode "ha" ) (and (eq (.Values.server.service.enabled | toString) "true" ) (eq (.Values.global.enabled | toString) "true")) }}
{{- $serviceName = printf "%s-%s" $serviceName "active" -}}
{{- end }}
{{- $servicePort := .Values.server.service.port -}}
apiVersion: extensions/v1beta1
kind: Ingress
Expand Down
10 changes: 5 additions & 5 deletions values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ server:
enabled: false
labels: {}
# traffic: external
annotations: {}
annotations: []
# |
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
Expand Down Expand Up @@ -232,7 +232,7 @@ server:
# Extra annotations to attach to the server pods
# This should be a multi-line string mapping directly to the a map of
# the annotations to apply to the server pods
annotations: {}
annotations: []

# Enables a headless service to be used by the Vault Statefulset
service:
Expand All @@ -259,7 +259,7 @@ server:
targetPort: 8200
# Extra annotations for the service definition. This should be a multi-line
# string formatted as a map of the annotations to apply to the service.
annotations: {}
annotations: []

# This configures the Vault Statefulset to create a PVC for data
# storage when using the file or raft backend storage engines.
Expand Down Expand Up @@ -403,7 +403,7 @@ server:
# Extra annotations for the serviceAccount definition. This should be a
# multi-line string formatted as a map of the annotations to apply to the
# serviceAccount.
annotations: {}
annotations: []

# Vault UI
ui:
Expand All @@ -426,4 +426,4 @@ ui:
# Extra annotations to attach to the ui service
# This should be a multi-line string mapping directly to the a map of
# the annotations to apply to the ui service
annotations: {}
annotations: []

0 comments on commit 6e11e40

Please sign in to comment.