<@ULVA73B9P> where can I get more information abou...
# ask-marvin
s
@Marvin where can I get more information about what the image pull policy values mean in the configuration of a Docker Work Pool?
m
thought for 725.2 seconds
Great question. In Prefect 3.x Docker Work Pools, the
image_pull_policy
accepts three values that follow the same semantics as Kubernetes: - Always: Always pull the image before starting the container - IfNotPresent: Only pull if the image is not already present locally - Never: Never pull; the image must already exist on the host Authoritative reference for these semantics: https://kubernetes.io/docs/concepts/containers/images/#image-pull-policy You can also see the accepted values in the Prefect Docker worker’s job configuration (from the
prefect-docker
collection):
Copy code
from prefect_docker.worker import DockerWorkerJobConfiguration

# Accepted values: 'Always', 'IfNotPresent', 'Never'
DockerWorkerJobConfiguration(
    image="myrepo/myimage:tag",
    image_pull_policy="IfNotPresent",
)
Source repo for the Prefect Docker collection: https://github.com/PrefectHQ/prefect-docker If you want, tell me how you’re deploying (UI vs. code) and I can point to the exact place to set it.