Docker somewhat recently introduced the ability to cache folders during image creation time, documented here: Build cache, and more on it here: Mounts guide.
Basically, rather than having to refetch all the packages each time the Python requirements change, it only needs to fetch the new ones, since it retains pip's cache between image builds. This should speed up run_local.sh when the requirements change. You'll only see this speedup once per requirements change, since after that all the layers will be cached and it should "build" nearly instantly, but if you're making frequent changes to the requirements it helps.
Docker somewhat recently introduced the ability to cache folders during image creation time, documented here: Build cache, and more on it here: Mounts guide.
Basically, rather than having to refetch all the packages each time the Python requirements change, it only needs to fetch the new ones, since it retains pip's cache between image builds. This should speed up
run_local.sh
when the requirements change. You'll only see this speedup once per requirements change, since after that all the layers will be cached and it should "build" nearly instantly, but if you're making frequent changes to the requirements it helps.