forked from Azure/azure-functions-host
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
28 lines (20 loc) · 855 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
FROM microsoft/dotnet:2.1-sdk AS installer-env
ENV PublishWithAspNetCoreTargetManifest false
COPY . /workingdir
RUN cd workingdir && \
dotnet build WebJobs.Script.sln && \
dotnet publish src/WebJobs.Script.WebHost/WebJobs.Script.WebHost.csproj --output /azure-functions-host
# Runtime image
FROM microsoft/dotnet:2.1-aspnetcore-runtime
RUN apt-get update && \
apt-get install -y gnupg && \
curl -sL https://deb.nodesource.com/setup_8.x | bash - && \
apt-get update && \
apt-get install -y nodejs
COPY --from=installer-env ["/azure-functions-host", "/azure-functions-host"]
COPY --from=installer-env ["/workingdir/sample", "/home/site/wwwroot"]
ENV AzureWebJobsScriptRoot=/home/site/wwwroot
ENV HOME=/home
ENV ASPNETCORE_URLS=http://+:80
EXPOSE 80
CMD dotnet /azure-functions-host/Microsoft.Azure.WebJobs.Script.WebHost.dll