Skip to content

Commit

Permalink
Add environment variables to Deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
aazon committed Jun 6, 2024
1 parent 6477b9d commit ddc756e
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 6 deletions.
2 changes: 1 addition & 1 deletion charts/shim-base/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ 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.1.0
version: 0.2.0

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
Expand Down
4 changes: 4 additions & 0 deletions charts/shim-base/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ spec:
{{- toYaml .Values.podSecurityContext | nindent 8 }}
containers:
- name: main
env:
{{- toYaml .Values.main.envs | nindent 12 }}
securityContext:
{{- toYaml .Values.main.securityContext | nindent 12 }}
image: "{{ .Values.main.image.repository }}:{{ .Values.main.image.tag | default .Chart.AppVersion }}"
Expand All @@ -51,6 +53,8 @@ spec:
{{- toYaml . | nindent 12 }}
{{- end }}
- name: shim
env:
{{- toYaml .Values.shim.envs | nindent 12 }}
securityContext:
{{- toYaml .Values.shim.securityContext | nindent 12 }}
image: "{{ .Values.shim.image.repository }}:{{ .Values.shim.image.tag }}"
Expand Down
30 changes: 25 additions & 5 deletions charts/shim-base/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,19 @@ podAnnotations: {}
podLabels: {}

podSecurityContext: {}
# fsGroup: 2000
# fsGroup: 2000

shim:
envs: []
# envs:
# - name: FOO
# valueFrom:
# secretKeyRef:
# key: FOO
# name: secret-resource
# - name: BAR
# value: 42

image:
repository: text-extr-shim
tag: ""
Expand All @@ -43,6 +53,16 @@ shim:
volumeMounts: []

main:
envs: []
# envs:
# - name: FOO
# valueFrom:
# secretKeyRef:
# key: FOO
# name: secret-resource
# - name: BAR
# value: 42

image:
repository: tika
tag: ""
Expand All @@ -63,8 +83,8 @@ securityContext: {}
# drop:
# - ALL
# readOnlyRootFilesystem: true
# runAsNonRoot: true
# runAsUser: 1000
# runAsNonRoot: true
# runAsUser: 1000

service:
type: ClusterIP
Expand All @@ -74,8 +94,8 @@ ingress:
enabled: false
className: ""
annotations: {}
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
# kubernetes.io/ingress.class: nginx
# kubernetes.io/tls-acme: "true"
hosts:
- host: chart-example.local
paths:
Expand Down

0 comments on commit ddc756e

Please sign in to comment.