<@ULVA73B9P> I have 2 deployments on a docker work...
# ask-marvin
r
@Marvin I have 2 deployments on a docker work pool scheduled to run every 15 minutes. Only one of these successfully completes while the other shows this error:
Copy code
docker.errors.ImageNotFound: 404 Client Error for <http+docker://localhost/v1.47/images/create?tag=dev&fromImage=eip>: Not Found ("pull access denied for eip, repository does not exist or may require 'docker login': denied: requested access to the resource is denied")
If they are run separately (out of band), the error does not happen. Can only one flow be run at a time?
m
Your issue seems to stem from a Docker image not being found, which might be due to several factors: 1. Image Tagging and Access: The error message indicates that the image
eip
is either not found or requires authentication. Ensure that the image is correctly tagged and accessible from your Docker registry. If authentication is required, make sure your Docker credentials are correctly set up and that you have logged in. 2. Concurrency and Image Pulling: When running multiple deployments concurrently, if both deployments attempt to pull the same image simultaneously, it might cause conflicts or race conditions. Prefect's Docker workers always attempt to pull the latest image if it's not available locally, which could lead to the issue you're experiencing. Consider ensuring that the image is pre-pulled or available locally. 3. Local Image Availability: If the image is only available locally and not in a remote repository, this can lead to errors when Prefect tries to pull it. You might want to adjust the
image_pull_policy
to
IF_NOT_PRESENT
to avoid unnecessary pulls if the image is already available locally. 4. Known Issues: There are known issues related to Docker image pulling in Prefect, such as the one where Docker pull fails silently if the disk is full or if there's a mismatch between PyPI and image releases. You might want to check these issues for any related problems. For more detailed information, you can refer to the Prefect Docker documentation and GitHub issues for similar problems and potential resolutions.
r
How do I set the image pull policy if I am using the .deploy() method in python?
n
image pull policy is set on the work pool so you can set that default or you can override via
job_variables
which
deploy()
accepts
👍 1
r
got it.
Appears to have fixed it. Nice! Thanks @Nate!
n
catjam
r
If I want to specify a volume or volume binding, would I do that in the work pool as well?
n
yep same deal, volumes is also a job variable on the work pool
r
nice