Created
January 21, 2020 23:43
-
-
Save mcopik/20ffbc1a5a70cb3fa4def3677bc06f17 to your computer and use it in GitHub Desktop.
Dockerifle for Azure CLI and Azure Function Tools
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| FROM python:3.7-slim-stretch | |
| ARG USER | |
| # disable telemetry by default | |
| ENV FUNCTIONS_CORE_TOOLS_TELEMETRY_OPTOUT=1 | |
| RUN apt-get update\ | |
| && apt-get install -y ca-certificates curl apt-transport-https lsb-release gnupg\ | |
| && curl -sL https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor\ | |
| | tee /etc/apt/trusted.gpg.d/microsoft.asc.gpg > /dev/null\ | |
| && AZ_REPO=$(lsb_release -cs)\ | |
| && echo "deb [arch=amd64] https://packages.microsoft.com/repos/azure-cli/ $AZ_REPO main"\ | |
| | tee /etc/apt/sources.list.d/azure-cli.list\ | |
| && echo "deb [arch=amd64] https://packages.microsoft.com/debian/9/prod $(lsb_release -cs) main" > /etc/apt/sources.list.d/dotnetdev.list\ | |
| && apt-get update\ | |
| && apt-get install -y azure-cli azure-functions-core-tools\ | |
| && az extension add --name application-insights | |
| # https://github.com/moby/moby/issues/20295 | |
| # https://github.com/moby/moby/issues/20295 | |
| ENV HOME=/home/${USER} | |
| RUN useradd --uid 1000 -m ${USER}\ | |
| && chown ${USER}:${USER} ${HOME} | |
| WORKDIR ${HOME} | |
| USER ${USER}:${USER} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment