From 1d4c4c3f220b77b0ffcd304c1435bb2a449125dc Mon Sep 17 00:00:00 2001 From: Hang Date: Wed, 25 Oct 2023 15:50:03 +0800 Subject: [PATCH] Init --- alpine.dockerfile | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/alpine.dockerfile b/alpine.dockerfile index 9773dc70e1b..dbc8756e2e9 100644 --- a/alpine.dockerfile +++ b/alpine.dockerfile @@ -34,11 +34,9 @@ LABEL maintainer="Microsoft" \ ARG JP_VERSION="0.2.1" -WORKDIR azure-cli -COPY . /azure-cli -RUN apk add --no-cache ca-certificates bash bash-completion libintl icu-libs libc6-compat jq openssh-keygen \ +RUN --mount=type=bind,target=/azure-cli,source=./,rw apk add --no-cache ca-certificates bash bash-completion libintl icu-libs libc6-compat jq openssh-keygen \ && apk add --no-cache --virtual .build-deps gcc musl-dev linux-headers libffi-dev curl \ - && update-ca-certificates && ./scripts/install_full.sh && python ./scripts/trim_sdk.py \ + && update-ca-certificates && cd /azure-cli && ./scripts/install_full.sh && python ./scripts/trim_sdk.py \ && cat /azure-cli/az.completion > ~/.bashrc \ && dos2unix /root/.bashrc /usr/local/bin/az \ && arch=$(arch | sed s/aarch64/arm64/ | sed s/x86_64/amd64/) && curl -L https://github.com/jmespath/jp/releases/download/${JP_VERSION}/jp-linux-$arch -o /usr/local/bin/jp \