FROM $base_image
COPY scripts/install_build_deps.sh scripts/version.sh tezos/scripts/
COPY tezos.opam tezos/
RUN sudo apk update && \
opam config exec -- ./tezos/scripts/install_build_deps.sh && \
sudo rm -f /var/cache/apk/* && \
rm -fr ~/.opam/log/ && \
rm -fr "$(opam config exec -- ocamlfind query stdlib)"/topdirs.cmi