diff --git a/charts/service/Chart.yaml b/charts/service/Chart.yaml index 8600835..c5dcbaf 100644 --- a/charts/service/Chart.yaml +++ b/charts/service/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: service description: A generic k8s service chart type: application -version: 1.8.6 +version: 1.8.7 maintainers: - email: devops@codecademy.com name: devops diff --git a/charts/service/templates/ingress-nlb.yaml b/charts/service/templates/ingress-nlb.yaml deleted file mode 100644 index 6d43a7e..0000000 --- a/charts/service/templates/ingress-nlb.yaml +++ /dev/null @@ -1,49 +0,0 @@ -{{- if .Values.ingress.enabled -}} -{{- $fullName := include "service.fullname" . -}} -apiVersion: networking.k8s.io/v1 -kind: Ingress -metadata: - name: {{ $fullName }}-nlb - labels: - {{- include "service.labels" . | nindent 4 }} - {{- with merge .Values.ingress.nlbIngressClassAnnotation .Values.ingress.annotations }} - annotations: - {{- toYaml . | nindent 4 }} - {{- end }} -spec: - {{- if .Values.ingress.tls }} - tls: - {{- range .Values.ingress.tls }} - - hosts: - {{- range .hosts }} - - {{ . | quote }} - {{- end }} - secretName: {{ .secretName }} - {{- end }} - {{- end }} - rules: - {{- range .Values.ingress.hosts }} - - host: {{ .host | quote }} - http: - paths: - {{- range .paths }} - {{- if (kindIs "map" .) }} - - path: {{ .path }} - pathType: ImplementationSpecific - backend: - service: - name: {{ .service }} - port: - name: http - {{- else }} - - path: {{ . }} - pathType: ImplementationSpecific - backend: - service: - name: {{ $fullName }} - port: - name: http - {{- end }} - {{- end }} - {{- end }} -{{- end }} diff --git a/charts/service/templates/ingress.yaml b/charts/service/templates/ingress.yaml index 68830b9..6d43a7e 100644 --- a/charts/service/templates/ingress.yaml +++ b/charts/service/templates/ingress.yaml @@ -3,10 +3,10 @@ apiVersion: networking.k8s.io/v1 kind: Ingress metadata: - name: {{ $fullName }} + name: {{ $fullName }}-nlb labels: {{- include "service.labels" . | nindent 4 }} - {{- with .Values.ingress.annotations }} + {{- with merge .Values.ingress.nlbIngressClassAnnotation .Values.ingress.annotations }} annotations: {{- toYaml . | nindent 4 }} {{- end }} diff --git a/charts/service/values.yaml b/charts/service/values.yaml index 649ebd5..f0ed18b 100644 --- a/charts/service/values.yaml +++ b/charts/service/values.yaml @@ -82,17 +82,12 @@ service: ingress: enabled: false annotations: {} - # kubernetes.io/ingress.class: nginx - # kubernetes.io/tls-acme: "true" + # kubernetes.io/ingress.class: nginx-nlb nlbIngressClassAnnotation: kubernetes.io/ingress.class: nginx-nlb hosts: - host: chart-example.local paths: [] - tls: [] - # - secretName: chart-example-tls - # hosts: - # - chart-example.local serviceAccount: # Specifies whether a service account should be created