Skip to content

Instantly share code, notes, and snippets.

@karthikeyanVK
Created November 6, 2019 18:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save karthikeyanVK/e8f38a80b502b41e525e1619a4acef3a to your computer and use it in GitHub Desktop.
Save karthikeyanVK/e8f38a80b502b41e525e1619a4acef3a to your computer and use it in GitHub Desktop.
FROM microsoft/dotnet:2.2-sdk AS installer-env
COPY . /src/dotnet-function-app
RUN cd /src/dotnet-function-app && \
mkdir -p /home/site/wwwroot && \
dotnet publish PetShop.Products/PetShop.Products.csproj --output /home/site/wwwroot
# To enable ssh & remote debugging on app service change the base image to the one below
# FROM mcr.microsoft.com/azure-functions/dotnet:2.0-appservice
FROM mcr.microsoft.com/azure-functions/dotnet:2.0
ENV AzureWebJobsScriptRoot=/home/site/wwwroot \
AzureFunctionsJobHost__Logging__Console__IsEnabled=true
COPY --from=installer-env ["/home/site/wwwroot", "/home/site/wwwroot"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment