VirusTotalNet icon indicating copy to clipboard operation
VirusTotalNet copied to clipboard

Stop using --no-cache with apk del

Open johnmccabe opened this issue 7 years ago • 1 comments

Expected Behaviour

We should not be using --no-cache with apk del.

Current Behaviour

Most alpine based template Dockerfiles have --no-cache set which results in the APK index being downloaded when set (you can see this occur by setting the --verbose flag).

# apk del nginx -v --no-cache
fetch http://dl-cdn.alpinelinux.org/alpine/v3.8/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.8/community/x86_64/APKINDEX.tar.gz
...

Possible Solution

Update Dockerfiles.

Steps to Reproduce (for bugs)

  1. apk add curl --no-cache
  2. apk del curl --no-cache --verbose

Context

Observed during review of php7 template.

Your Environment

Alpine

johnmccabe avatar Sep 28 '18 15:09 johnmccabe

Approved

alexellis avatar Sep 28 '18 15:09 alexellis