Skip to content

Commit

Permalink
PAG svc ingress
Browse files Browse the repository at this point in the history
  • Loading branch information
alvarof2 committed Nov 28, 2024
1 parent 37e51b4 commit ebfb374
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
2 changes: 1 addition & 1 deletion charts/prom-aggregation-gateway/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v2
name: prom-aggregation-gateway
version: 0.0.2
version: 0.0.3
home: https://github.com/zapier/prom-aggregation-gateway
appVersion: latest
description: cLabs prometheus aggregation gateway
Expand Down
4 changes: 4 additions & 0 deletions charts/prom-aggregation-gateway/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,7 @@ app.kubernetes.io/managed-by: {{ .Release.Service }}
app.kubernetes.io/name: {{ include "prom-aggregation-gateway.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{- define "prom-aggregation-gateway.api-port" -}}
{{- .Values.service.port }}
{{- end -}}
6 changes: 4 additions & 2 deletions charts/prom-aggregation-gateway/templates/ingress.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
{{- if .Values.ingress.enabled -}}
{{- $fullName := include "prom-aggregation-gateway.fullname" . -}}
{{- $svcPort := include "prom-aggregation-gateway.api-port" . -}}
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
Expand Down Expand Up @@ -33,9 +35,9 @@ spec:
{{- end }}
backend:
service:
name: {{ include "prom-aggregation-gateway.fullname" . }}
name: {{ $fullName }}
port:
number: api-port
number: {{ $svcPort }}
{{- end }}
{{- end }}
{{- end }}

0 comments on commit ebfb374

Please sign in to comment.