Open tekumara opened 1 year ago
As I workaround I have to explicitly tell prefect to set the working dir to that of my docker image:
pull:
# required see https://github.com/PrefectHQ/prefect/issues/10285
- prefect.deployments.steps.set_working_directory:
directory: /opt/prefect
Could prefect just use the the docker image's default WORKDIR instead?
Same for me with Apple silicon. Wonder if it's an os or hardware specific issue.
Even the Prefect staff encounter this issue. You can watch this video for reference: https://youtu.be/JKdN9bWIaSw?t=1019
It seems the root cause of this issue is the absence of properly set job variables. Specifically, the image variable is missing, which results in pulling the wrong image.
I was able to resolve this by setting the image variable, as shown in the video. If you're not using Docker Hub like me, you'll need to set your image to image_name:tag
, where these values come from your prefect_docker.deployments.steps.build_docker_image
settings.
First check
Bug summary
When the flow runs, Prefect tries to set a working directory to the dir on the host, used when creating the deployment, and fails.
My prefect.yaml does not include any
prefect.deployments.steps.set_working_directory
step:I wouldn't expect this to implicitly happen if I hadn't defined a step to do so.
Reproduction
Error
No response
Versions
Additional context
No response