Skip to content

Commit

Permalink
Service annotations (#51)
Browse files Browse the repository at this point in the history
* Add annotation support for services

* Add service annotations to chia chart
  • Loading branch information
cmmarslender authored Jun 13, 2024
1 parent 0436107 commit aaddcf2
Show file tree
Hide file tree
Showing 9 changed files with 22 additions and 4 deletions.
2 changes: 1 addition & 1 deletion charts/chia-blockchain/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.7.0
version: 0.7.1
4 changes: 4 additions & 0 deletions charts/chia-blockchain/templates/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ metadata:
name: {{ include "chia-blockchain.fullname" . }}
labels:
{{- include "chia-blockchain.labels" . | nindent 4 }}
{{- with .Values.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
type: {{ .Values.service.type }}
{{- if .Values.service.externalTrafficPolicy }}
Expand Down
2 changes: 2 additions & 0 deletions charts/chia-blockchain/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,8 @@ chiaExporter:
service:
type: ClusterIP
externalTrafficPolicy: ""
annotations: {}
# external-dns.alpha.kubernetes.io/hostname: testing.example.com

localService:
type: ClusterIP
Expand Down
2 changes: 1 addition & 1 deletion charts/generic-stateful/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ apiVersion: v2
name: generic-stateful
description: A generic helm chart that handles a bunch of common stateful set deploy cases
type: application
version: 0.3.4
version: 0.3.5
4 changes: 4 additions & 0 deletions charts/generic-stateful/templates/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ metadata:
{{- with .Values.service.additionalLabels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
type: {{ .Values.service.type }}
ports:
Expand Down
4 changes: 3 additions & 1 deletion charts/generic-stateful/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ serviceAccount:
name: ""

# Specifies whether to recreate Pods on a redeploy if nothing else about the underlying Pods changed.
# This is useful for Statefulsets that deploy an unchanging image tag like :latest,
# This is useful for Statefulsets that deploy an unchanging image tag like :latest,
# but still want the Pods to recreate to use the image pullPolicy to re-pull the image.
# This creates an annotation on the Pods with the current helm release number.
recreatePodsOnUpgrade: false
Expand Down Expand Up @@ -76,6 +76,8 @@ service:
additionalLabels: {}
# application: my-application
# prometheus: application-metrics
annotations: {}
# external-dns.alpha.kubernetes.io/hostname: testing.example.com
port: 80

ingress:
Expand Down
2 changes: 1 addition & 1 deletion charts/generic/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ apiVersion: v2
name: generic
description: A generic helm chart that handles a bunch of common application deploy cases
type: application
version: 1.11.0
version: 1.11.1
4 changes: 4 additions & 0 deletions charts/generic/templates/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ metadata:
{{- with .Values.service.additionalLabels }}
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
type: {{ .Values.service.type }}
ports:
Expand Down
2 changes: 2 additions & 0 deletions charts/generic/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,8 @@ service:
additionalLabels: {}
# application: my-application
# prometheus: application-metrics
annotations: {}
# external-dns.alpha.kubernetes.io/hostname: testing.example.com
port: 80
additionalPorts: []
# - port: 9101
Expand Down

0 comments on commit aaddcf2

Please sign in to comment.