Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion demo-targets/http-webhook/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ spec:
imagePullPolicy: {{ .Values.image.pullPolicy }}
ports:
- name: http
containerPort: 80
containerPort: 8080
protocol: TCP
resources:
{{- toYaml .Values.resources | nindent 12 }}
Expand Down
15 changes: 7 additions & 8 deletions demo-targets/http-webhook/templates/ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,10 @@
#
# SPDX-License-Identifier: Apache-2.0

{{- if .Values.ingress.enabled -}}
{{ if .Values.ingress.enabled -}}
{{- $fullName := include "http-webhook.fullname" . -}}
{{- $svcPort := .Values.service.port -}}
{{- if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion -}}
apiVersion: networking.k8s.io/v1beta1
{{- else -}}
apiVersion: extensions/v1beta1
{{- end }}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
name: {{ $fullName }}
Expand Down Expand Up @@ -37,9 +33,12 @@ spec:
paths:
{{- range .paths }}
- path: {{ . }}
pathType: Prefix
backend:
serviceName: {{ $fullName }}
servicePort: {{ $svcPort }}
service:
name: {{ $fullName }}
port:
name: http
{{- end }}
{{- end }}
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ matches the snapshot:
imagePullPolicy: IfNotPresent
name: http-webhook
ports:
- containerPort: 80
- containerPort: 8080
name: http
protocol: TCP
resources:
Expand Down Expand Up @@ -93,6 +93,7 @@ matches the snapshot:
kind: Deployment
name: bar
4: |
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
annotations:
Expand Down
Loading