Hello, i'm trying to deploy my flow from python fo...
# ask-community
r
Hello, i'm trying to deploy my flow from python following the documentation. My python code is:
Copy code
myFlow_v0.deploy(
    name="myFlow_v0",
    work_pool_name="my-pool",
    image=DeploymentImage(
        name="my-image:latest",
        dockerfile="./../../Dockerfile",
        platform="linux/amd64",
    )
)
but i encounter in
prefect.utilities.dockerutils.BuildError: COPY failed: file not found in build context or excluded by .dockerignore
when, into the Dockerfile, it tries to run the command
COPY myfile .
It seems like it uses, as build context, the path of my flow.py file and not the Dockerfile posix, anyone have some hint for this?
r
If you’re not using external storage, it looks for the code using the same path as you’re running your deploy from i.e running python deploy.py and python prefect/deploy.py is different