diff --git a/charts/prometheus-opencost-exporter/templates/service.yaml b/charts/prometheus-opencost-exporter/templates/service.yaml new file mode 100644 index 000000000000..ecf7723dd718 --- /dev/null +++ b/charts/prometheus-opencost-exporter/templates/service.yaml @@ -0,0 +1,21 @@ +{{- if .Values.service.enabled }} +apiVersion: v1 +kind: Service +metadata: + name: {{ include "prometheus-opencost-exporter.fullname" . }} + labels: + {{- include "prometheus-opencost-exporter.labels" . | nindent 4 }} + {{- with .Values.service.labels }} + {{- toYaml . | nindent 4 }} + {{- end }} + {{- with .Values.service.annotations }} + annotations: {{- toYaml . | nindent 4 }} + {{- end }} +spec: + selector: {{- include "prometheus-opencost-exporter.selectorLabels" . | nindent 4 }} + type: {{ .Values.service.type }} + ports: + - name: http + port: 9003 + targetPort: 9003 +{{- end }}