Skip to content

Commit

Permalink
add extraPorts for extraContainers
Browse files Browse the repository at this point in the history
In parallel to extraContainers, extraPorts may be required to scrape
additional metrics generated by said extraContainers.
  • Loading branch information
cruwe committed Jan 13, 2023
1 parent cdd8e59 commit ba7d561
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
3 changes: 3 additions & 0 deletions charts/kminion/templates/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,8 @@ spec:
targetPort: metrics
protocol: TCP
name: metrics
{{- if .Values.service.extraPorts }}
{{- toYaml .Values.service.extraPorts | nindent 4 }}
{{- end }}
selector:
{{- include "kminion.selectorLabels" . | nindent 4 }}
7 changes: 7 additions & 0 deletions charts/kminion/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,13 @@ service:
type: ClusterIP
port: 8080 # This port is also used as exposed container port
annotations: {} # # Annotations to add to the service
extraPorts: [] # when []extraContainers expose additional metrics, make
# discoverable for servicemontors
# - port: 8443
# targetPort: 8443
# protocol: TCP
# name: expose-x509-for-ttl-checks


ingress:
enabled: false
Expand Down

0 comments on commit ba7d561

Please sign in to comment.