BuildKit icon indicating copy to clipboard operation
BuildKit copied to clipboard

Example how to cache for perl `cpm`

Open KES777 opened this issue 3 years ago • 0 comments

FROM perl

RUN  cpanm -n -L ./local App::cpm Carton::Snapshot  && rm -rf /root/.cpanm
COPY cpanfile ./
COPY cpanfile.snapshot ./

RUN  --mount=type=cache,id=perl,target=/root/.perl-cpm   \
  cpm install  -w 16  --no-test  -L ./local   

KES777 avatar Jun 19 '22 23:06 KES777