Skip to content

Instantly share code, notes, and snippets.

@EvilFreelancer
Created April 25, 2023 23:18
Show Gist options
  • Select an option

  • Save EvilFreelancer/db5e70c635467be2a8c0526aed81a62c to your computer and use it in GitHub Desktop.

Select an option

Save EvilFreelancer/db5e70c635467be2a8c0526aed81a62c to your computer and use it in GitHub Desktop.
Использование "хуков"
# templates/post-install-job.yaml
apiVersion: batch/v1
kind: Job
metadata:
name: {{ .Release.Name }}-post-install
annotations:
"helm.sh/hook": post-install
"helm.sh/hook-weight": "10"
spec:
template:
spec:
containers:
- name: post-install
image: "{{ .Values.postInstallJob.image.repository }}:{{ .Values.postInstallJob.image.tag }}"
command: ['sh', '-c', '/scripts/post-install.sh']
restartPolicy: OnFailure
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment