Skip to content
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

feat: add extraMounts and volumes to migrate job #147

Merged
merged 2 commits into from
Aug 7, 2024
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
8 changes: 8 additions & 0 deletions charts/openfga/templates/job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,18 @@ spec:

resources:
{{- toYaml .Values.datastore.migrations.resources | nindent 12 }}
{{- with .Values.migrate.extraVolumeMounts }}
volumeMounts:
{{- toYaml . | nindent 12 }}
{{- end }}
{{- if .Values.migrate.sidecars }}
{{- include "common.tplvalues.render" ( dict "value" .Values.migrate.sidecars "context" $) | nindent 8 }}
{{- end }}
restartPolicy: Never
{{- with .Values.migrate.extraVolumes }}
volumes:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
Expand Down
10 changes: 10 additions & 0 deletions charts/openfga/values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -925,6 +925,16 @@
"description": "add additional sidecar containers to the migration job",
"default": []
},
"extraVolumes": {
"type": "array",
"description": "add additional volumes to the migration job",
"default": []
},
"extraVolumeMounts": {
"type": "array",
"description": "add additional volumeMounts to the migration job",
"default": []
},
"annotations": {
"type": "object",
"description": "Map of annotations to add to the migration job's manifest",
Expand Down
2 changes: 2 additions & 0 deletions charts/openfga/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,8 @@ affinity: {}
# containerPort: 1234
sidecars: []
migrate:
extraVolumes: []
extraVolumeMounts: []
sidecars: []
annotations:
helm.sh/hook: "post-install, post-upgrade, post-rollback, post-delete"
Expand Down