Skip to content

Commit

Permalink
Add ability to specify pod template annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
rocktavious committed Dec 4, 2024
1 parent 66958f0 commit bfb1d4f
Show file tree
Hide file tree
Showing 17 changed files with 68 additions and 0 deletions.
3 changes: 3 additions & 0 deletions charts/opslevel/templates/elasticsearch/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ spec:
app.kubernetes.io/part-of: elasticsearch
annotations:
checksum/secret: {{ include (print $.Template.BasePath "/elasticsearch/secret.yaml") . | sha256sum }}
{{- with .Values.elasticsearch.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/faktory/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ spec:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/faktory/configmap.yaml") . | sha256sum }}
checksum/secret: {{ include (print $.Template.BasePath "/faktory/secret.yaml") . | sha256sum }}
{{- with .Values.faktory.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/minio/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ spec:
app.kubernetes.io/part-of: minio
annotations:
checksum/secret: {{ include (print $.Template.BasePath "/elasticsearch/secret.yaml") . | sha256sum }}
{{- with .Values.objectStorage.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/mysql/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ spec:
app.kubernetes.io/part-of: mysql
annotations:
checksum/secret: {{ include (print $.Template.BasePath "/mysql/secret.yaml") . | sha256sum }}
{{- with .Values.mysql.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/opslevel/scheduler.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ spec:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/opslevel/configmap.yaml") . | sha256sum }}
checksum/secret: {{ include (print $.Template.BasePath "/opslevel/secret.yaml") . | sha256sum }}
{{- with .Values.opslevel.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/opslevel/web.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ spec:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/opslevel/configmap.yaml") . | sha256sum }}
checksum/secret: {{ include (print $.Template.BasePath "/opslevel/secret.yaml") . | sha256sum }}
{{- with .Values.opslevel.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/opslevel/worker-faktory.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ spec:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/opslevel/configmap.yaml") . | sha256sum }}
checksum/secret: {{ include (print $.Template.BasePath "/opslevel/secret.yaml") . | sha256sum }}
{{- with .Values.opslevel.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/opslevel/worker-high.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ spec:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/opslevel/configmap.yaml") . | sha256sum }}
checksum/secret: {{ include (print $.Template.BasePath "/opslevel/secret.yaml") . | sha256sum }}
{{- with .Values.opslevel.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/opslevel/worker-low.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ spec:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/opslevel/configmap.yaml") . | sha256sum }}
checksum/secret: {{ include (print $.Template.BasePath "/opslevel/secret.yaml") . | sha256sum }}
{{- with .Values.opslevel.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/opslevel/worker-search.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ spec:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/opslevel/configmap.yaml") . | sha256sum }}
checksum/secret: {{ include (print $.Template.BasePath "/opslevel/secret.yaml") . | sha256sum }}
{{- with .Values.opslevel.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/opssight/web.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ spec:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/opssight/configmap.yaml") . | sha256sum }}
checksum/secret: {{ include (print $.Template.BasePath "/opssight/secret.yaml") . | sha256sum }}
{{- with .Values.opssight.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/opssight/worker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ spec:
annotations:
checksum/config: {{ include (print $.Template.BasePath "/opssight/configmap.yaml") . | sha256sum }}
checksum/secret: {{ include (print $.Template.BasePath "/opssight/secret.yaml") . | sha256sum }}
{{- with .Values.opssight.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/postgres/statefulset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ spec:
app.kubernetes.io/part-of: postgres
annotations:
checksum/secret: {{ include (print $.Template.BasePath "/postgres/secret.yaml") . | sha256sum }}
{{- with .Values.postgres.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
5 changes: 5 additions & 0 deletions charts/opslevel/templates/redis/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@ spec:
labels:
app.kubernetes.io/component: app
app.kubernetes.io/part-of: redis
annotations:
checksum/secret: {{ include (print $.Template.BasePath "/redis/secret.yaml") . | sha256sum }}
{{- with .Values.redis.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "opslevel.pullSecrets" . }}
{{- template "global.nodeSelector" . }}
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/runner/new-mode.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ spec:
app.kubernetes.io/part-of: runner-faktory
annotations:
checksum/secret: {{ include (print $.Template.BasePath "/runner/secret.yaml") . | sha256sum }}
{{- with .Values.runner.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "global.nodeSelector" . }}
priorityClassName: opslevel-normal
Expand Down
3 changes: 3 additions & 0 deletions charts/opslevel/templates/runner/old-mode.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ spec:
app.kubernetes.io/part-of: runner
annotations:
checksum/secret: {{ include (print $.Template.BasePath "/runner/secret.yaml") . | sha256sum }}
{{- with .Values.runner.pod.annotations }}
{{ toYaml . | indent 8 }}
{{- end }}
spec:
{{- template "global.nodeSelector" . }}
priorityClassName: opslevel-normal
Expand Down
18 changes: 18 additions & 0 deletions charts/opslevel/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ opslevel:
username: "Alice Wonderland"
email: "[email protected]"
password: "wonderland"
pod:
annotations: {}
web:
replicas: 3
resources: *resourcesMedium
Expand All @@ -71,6 +73,8 @@ runner:
tag: "v2024.10.14"
replicas: 3
resources: *resourcesLarge
pod:
annotations: {}
secret:
name: "opslevel-runner"
create: true
Expand All @@ -81,6 +85,8 @@ opssight:
image:
repository: "746108190720.dkr.ecr.us-east-1.amazonaws.com/opssight"
tag: "selfhosted-production-b8a797f-1726845192"
pod:
annotations: {}
web:
replicas: 2
resources: *resourcesMedium
Expand All @@ -98,6 +104,8 @@ mysql:
repository: "746108190720.dkr.ecr.us-east-1.amazonaws.com/mysql"
tag: "8.0.34-debian"
resources: *resourcesMedium
pod:
annotations: {}
serviceAccount:
create: true
name: mysql
Expand All @@ -118,6 +126,8 @@ postgres:
repository: "746108190720.dkr.ecr.us-east-1.amazonaws.com/postgres"
tag: "16.1-bookworm"
resources: *resourcesMedium
pod:
annotations: {}
serviceAccount:
create: true
name: postgres
Expand All @@ -138,6 +148,8 @@ redis:
repository: "746108190720.dkr.ecr.us-east-1.amazonaws.com/redis"
tag: "6.2.6"
resources: *resourcesMedium
pod:
annotations: {}
secret:
create: true
name: "opslevel-redis"
Expand All @@ -153,6 +165,8 @@ elasticsearch:
repository: "746108190720.dkr.ecr.us-east-1.amazonaws.com/elasticsearch"
tag: "8.8.2"
resources: *resourcesLarge
pod:
annotations: {}
serviceAccount:
create: true
name: elasticsearch
Expand All @@ -175,6 +189,8 @@ objectStorage:
repositoryCLI: "minio/mc"
tagCLI: "RELEASE.2023-02-28T00-12-59Z"
resources: *resourcesMedium
pod:
annotations: {}
serviceAccount:
create: true
name: minio
Expand All @@ -195,6 +211,8 @@ faktory:
resources: *resourcesMedium
storageClass: ""
storageSize: "8Gi"
pod:
annotations: {}
secret:
name: "opslevel-faktory"
password: "admin1234"
Expand Down

0 comments on commit bfb1d4f

Please sign in to comment.