diff --git a/charts/openfga/templates/job.yaml b/charts/openfga/templates/job.yaml index ee04094..8a1acdc 100644 --- a/charts/openfga/templates/job.yaml +++ b/charts/openfga/templates/job.yaml @@ -52,6 +52,11 @@ spec: key: "uri" {{- end }} + {{- if .Values.migrate.timeout }} + - name: OPENFGA_TIMEOUT + value: "{{ .Values.migrate.timeout }}" + {{- end }} + {{- with .Values.extraEnvVars }} {{- toYaml . | nindent 12 }} {{- end }} diff --git a/charts/openfga/values.schema.json b/charts/openfga/values.schema.json index 89f6115..19f5c9b 100644 --- a/charts/openfga/values.schema.json +++ b/charts/openfga/values.schema.json @@ -924,15 +924,24 @@ "type": "array", "description": "add additional sidecar containers to the migration job", "default": [] - } - }, - "annotations": { - "type": "object", - "description": "Map of annotations to add to the migration job's manifest", - "additionalProperties": { - "type": "string" }, - "default": {} + "annotations": { + "type": "object", + "description": "Map of annotations to add to the migration job's manifest", + "additionalProperties": { + "type": "string" + }, + "default": {} + }, + "timeout": { + "type": [ + "string", + "null" + ], + "description": "A timeout for the time it takes the migrate process to connect to the database", + "format": "duration", + "default": "1m" + } } }, "extraEnvVars": { diff --git a/charts/openfga/values.yaml b/charts/openfga/values.yaml index 0564d9d..5222fe7 100644 --- a/charts/openfga/values.yaml +++ b/charts/openfga/values.yaml @@ -325,3 +325,4 @@ migrate: helm.sh/hook-weight: "-5" helm.sh/hook-delete-policy: "before-hook-creation" labels: {} + timeout: