Dockerfile
.
COPY
.
# Copy all files from the model repo to the current WORKDIR
COPY --link --from=depot.ai/runwayml/stable-diffusion-v1-5 / .
# COPY just one file from the model repo to the current WORKDIR
COPY --link --from=depot.ai/runwayml/stable-diffusion-v1-5 /v1-5-pruned.ckpt .
Compared to alternatives like git lfs clone
, depot.ai images build faster, are cached between builds, and only store the model layer once in your
registry, reducing storage and bandwidth.
Each model image includes an eStargz index, which allows Docker's BuildKit to download only the files copied from the model during the build. If you build images with Depot, this index is automatically used. Otherwise you will need to enable eStargz in your image builder.