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

add plugins support for k8s imagepullpolicy #5167

Merged
merged 2 commits into from
Apr 15, 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
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,9 @@ type K8sPluginConfig struct {
// one, and the corresponding task marked as failed
ImagePullBackoffGracePeriod config2.Duration `json:"image-pull-backoff-grace-period" pflag:"-,Time to wait for transient ImagePullBackoff errors to be resolved."`

// ImagePullPolicy for the submitted pod.
ImagePullPolicy v1.PullPolicy `json:"image-pull-policy" pflag:"-,Image pull policy for all k8s pods created by FlytePropeller."`

// Time to wait while pod is in pending phase. If the pod is stuck in
// pending phase past this timeout, it will be inferred to be a permanent
// issue, and the corresponding task marked as failed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,7 @@ func BuildRawContainer(ctx context.Context, tCtx pluginscore.TaskExecutionContex
Env: ToK8sEnvVar(taskContainer.GetEnv()),
TerminationMessagePolicy: v1.TerminationMessageFallbackToLogsOnError,
Resources: *res,
ImagePullPolicy: config.GetK8sPluginConfig().ImagePullPolicy,
}

return container, nil
Expand Down
Loading