Hey @SolarUltima ,
There’s only really three methods to do this, and I see you are removing cache that involves
18f.gov, which is a US Government entity that deals with the GSA.
That said, Docker images are one example explicitly called out as a thing we really to not cache. I’ll quote the snippet of what the documentation says below:
Large files that are quick to install but slow to download do not benefit from caching, as they take as long to download from the cache as from the original source.
There are however three ways you can clear cache in Travis, these are the following:
- Using the UI: “More options” → “Caches” on the repo’s page
- Using the CLI:
travis cache --delete
- Using the API:
.travis.yml you provided - it’s not really clear what’s involved in the build pipeline beyond that Dockerfile, and even then it looks like it’s wrong as it should be
Dockerfile . in this case. If the file itself hasn’t changed, any of the things that go into it (base image, manifest, digest, source code, etc.) might have. Caching the image means you may get false positives, builds that pass even though
docker build would have failed.
So theoretically it could be a lose-lose situation, and you might be better off starting over with the Dockerfile. My advice to you is to make a bash script, and clean this
.travis.yml up a bit and you should be on your way. If you have issues creating the bash file, I’ll create one for you.