Skip to content
This repository was archived by the owner on Feb 13, 2019. It is now read-only.
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion templates/Dockerfile.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,22 @@
<% if(!coreclr){ %>FROM microsoft/aspnet:1.0.0-rc1-final<% } %><% if(coreclr){ %>FROM microsoft/aspnet:1.0.0-rc1-final-coreclr<% } %>

COPY . /app
# for any project involving EntityFramework, SQLLITE3 must be a version >= 3.7.15
RUN printf "deb http://ftp.us.debian.org/debian jessie main\n" >> /etc/apt/sources.list
RUN apt-get -qq update && apt-get install -qqy sqlite3 libsqlite3-dev

# The reason we copy the project.json first is related to the way that
# Docker's "union file system" works. Each command in sequence gets cached
# on the docker host as a binary. Commands that are "unchanged" from the
# previous run will not be run a second time.
#
# By changing the order here, docker's "restart" of a container will only
# run a full nuget restore when a project's dependencies change, as opposed
# to when any code changes at all.
#
COPY ./project.json /app/project.json
WORKDIR /app
RUN ["dnu", "restore"]
COPY . /app

EXPOSE 5000/tcp
ENTRYPOINT ["dnx", "-p", "project.json", "web"]