Santandersecurityresearch / asvs

A simple web app that helps developers understand the ASVS requirements.
MIT License
154 stars 39 forks source link

541MB docker image layer not cached #57

Open LukeKeywalker opened 3 years ago

LukeKeywalker commented 3 years ago

Following step is not being cached by the docker build process which takes a lot of time and storage both while building the container and while pushing it to the private registry:

RUN apk add --virtual build-deps --no-cache gcc python3-dev musl-dev zlib-dev postgresql-dev jpeg-dev

Steps to reproduce: 1) Build the image with docker build -t asvs . 2) Make any change, for example add new allowed host to asvs/settings.py 3) Build image again with docker build -t asvs . 4) Watch mentioned step being executed again

~I guess it's because of --no-cache flag so I was wondering what is the reason for using it~? Would there be a way to make this build step cacheable?

EDIT: