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

Avoid redundant image builds with prefect.yaml #16191

Closed
EmilRex opened this issue Dec 3, 2024 · 2 comments
Closed

Avoid redundant image builds with prefect.yaml #16191

EmilRex opened this issue Dec 3, 2024 · 2 comments
Labels
enhancement An improvement of an existing feature

Comments

@EmilRex
Copy link
Contributor

EmilRex commented Dec 3, 2024

Describe the current behavior

When deploying multiple flows with prefect.yaml users want the ability to build a single common Docker image as opposed to one per flow. Managing and building 10s or 100s of images becomes burdensome when you are building a single Docker container with all your code.

Consider the following Dockerfile:

FROM prefecthq/prefect:3-latest

COPY . .

RUN pip install -r requirements.txt

This image will identical for all deployments, but will be built once for each deployment.

Describe the proposed behavior

When running prefect deploy with multiple deployments in a prefect.yaml file that share a common image, the image should be built only once.

Example Use

No response

Additional context

No response

@EmilRex EmilRex added the enhancement An improvement of an existing feature label Dec 3, 2024
@zzstoatzz
Copy link
Collaborator

zzstoatzz commented Dec 3, 2024

hi @EmilRex - hmm can you confirm that this is not solved by #13286?

I opened #12928 a while ago, which should be closed by the above

if not, what version of prefect-docker is being used?

@EmilRex
Copy link
Contributor Author

EmilRex commented Dec 4, 2024

@zzstoatzz hmm that definitely looks like it solves it. I must have been using an older version. I'll close this issue and can always re-open if necessary. Apologies for the confusion!

@EmilRex EmilRex closed this as completed Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An improvement of an existing feature
Projects
None yet
Development

No branches or pull requests

2 participants