The main slowdown for you would then be
Docker
storage building. This is less a question about how to configure prefect, and more a question about how to speedup docker storage builds. A few tips:
• If you have lots of custom dependencies, you might build a custom base image used by all your flows, and set this as
base_image
. Then your flow build would only need to add the flow source to the image before registering.
• Alternatively you might use a different storage type (
S3
,
Github
, ...) for hosting your flow source, and configure a static image on your flow separately. To do that using the legacy environment-based system you'd set
flow.environment.metadata["image"] = "your-image-name"
). If you're using a
KubernetesRun
run-config, this would just be the
image
parameter to that object.