Skip to content

feat: Add ability to configure coder container lifecycle hooks in helm chart #6432

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions helm/templates/coder.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ spec:
imagePullPolicy: {{ .Values.coder.image.pullPolicy }}
resources:
{{- toYaml .Values.coder.resources | nindent 12 }}
lifecycle:
{{- toYaml .Values.coder.lifecycle | nindent 12 }}
env:
- name: CODER_HTTP_ADDRESS
value: "0.0.0.0:8080"
Expand Down
12 changes: 12 additions & 0 deletions helm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,18 @@ coder:
# "CODER_TLS_*" environment variables will be set for you.
secretNames: []

# coder.lifecycle -- container lifecycle handlers for the Coder container, allowing
# for lifecycle events such as postStart and preStop events
# See: https://kubernetes.io/docs/tasks/configure-pod-container/attach-handler-lifecycle-event/
lifecycle:
{}
# postStart:
# exec:
# command: ["/bin/sh", "-c", "echo postStart"]
# preStop:
# exec:
# command: ["/bin/sh","-c","echo preStart"]

# coder.resources -- The resources to request for Coder. These are optional
# and are not set by default.
resources:
Expand Down