docker: Cache web packages while building
build.sh previously downloaded the toolchains and fvp from the web
everytime it was invoked and deleted them when finished. This is
expensive, but worse, on the CI, wget is not available in the container
we must use to build the image.
So let's store the packages in a separate `assets` subdirectory, and
first check if what we need is there before downloading it. Additionally
don't delete them when finished. Locally, this avoids subsequent
invocations needing to download the packages. On the CI, we can cache
the directory so that subsequent pipelines are faster.
Finally add a special version, `none`, which if specified, syncs the
package cache but exits without actually building any images. This is
useful to enable separating the process of populating the cache on CI.
Signed-off-by:
Ryan Roberts <ryan.roberts@arm.com>
Loading
Please register or sign in to comment