This Github Action caches docker builds using the official actions/cache library.
Variable | Description |
---|---|
args |
Required Arguments passed to docker build command |
cache_key |
Required Key used for caching |
uses: mattes/cached-docker-build-action@v1
with:
args: "--pull --file Dockerfile --tag my-image:tag ."
cache_key: "${{ hashFiles('**/lockfiles') }}"
- Implement
expires
flag, blocked by Clear cache #2.