2016-09-07 17:15:13 -07:00
|
|
|
FROM microsoft/dotnet:1.0.0-preview2-sdk
|
|
|
|
|
|
|
|
#Lighter image if copying the compiled app and entrypoint as ENTRYPOINT dotnet Ordering.API.dll
|
|
|
|
#FROM microsoft/dotnet:1.0.0-core
|
|
|
|
|
|
|
|
# Set the Working Directory
|
|
|
|
WORKDIR /app
|
|
|
|
|
2016-09-14 00:44:13 -07:00
|
|
|
# Configure the listening port to 80
|
|
|
|
ENV ASPNETCORE_URLS http://*:80
|
2016-09-07 17:15:13 -07:00
|
|
|
|
|
|
|
# Open port exposed by Docker
|
2016-09-14 00:44:13 -07:00
|
|
|
EXPOSE 80/tcp
|
2016-09-07 17:15:13 -07:00
|
|
|
|
|
|
|
# Copy the app
|
|
|
|
COPY . /app
|
|
|
|
|
|
|
|
#################
|
|
|
|
# Restore NuGet packages
|
2016-09-14 00:44:13 -07:00
|
|
|
#RUN ["dotnet", "restore"]
|
2016-09-07 17:15:13 -07:00
|
|
|
|
|
|
|
# Build the .NET Core app
|
2016-09-14 00:44:13 -07:00
|
|
|
#RUN ["dotnet", "build"]
|
2016-09-07 17:15:13 -07:00
|
|
|
|
|
|
|
# Entrypoint
|
2016-09-14 00:44:13 -07:00
|
|
|
#ENTRYPOINT ["dotnet", "run"]
|
2016-09-07 17:15:13 -07:00
|
|
|
#################
|
|
|
|
|
|
|
|
# Entry point through the copied assembly
|
2016-09-14 00:44:13 -07:00
|
|
|
ENTRYPOINT dotnet Ordering.API.dll
|