Copy only project.json before dotnet restore in Dockerfile templates
This commit is contained in:
parent
cf1a127e7d
commit
a631f77a33
|
|
@ -3,12 +3,12 @@ FROM microsoft/dotnet:latest
|
|||
RUN apt-get update
|
||||
RUN apt-get install -y build-essential nodejs nodejs-legacy
|
||||
|
||||
COPY . /app
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY project.json .
|
||||
RUN ["dotnet", "restore"]
|
||||
|
||||
COPY . /app
|
||||
RUN ["dotnet", "build"]
|
||||
|
||||
EXPOSE 5000/tcp
|
||||
|
|
|
|||
|
|
@ -3,12 +3,12 @@ FROM microsoft/dotnet:latest
|
|||
RUN apt-get update
|
||||
RUN apt-get install -y build-essential nodejs nodejs-legacy
|
||||
|
||||
COPY . /app
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY project.json .
|
||||
RUN ["dotnet", "restore"]
|
||||
|
||||
COPY . /app
|
||||
RUN ["dotnet", "build"]
|
||||
|
||||
EXPOSE 5000/tcp
|
||||
|
|
|
|||
|
|
@ -3,12 +3,12 @@ FROM microsoft/dotnet:latest
|
|||
RUN apt-get update
|
||||
RUN apt-get install -y build-essential nodejs nodejs-legacy
|
||||
|
||||
COPY . /app
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY project.json .
|
||||
RUN ["dotnet", "restore"]
|
||||
|
||||
COPY . /app
|
||||
RUN ["dotnet", "build"]
|
||||
|
||||
EXPOSE 5000/tcp
|
||||
|
|
|
|||
|
|
@ -3,12 +3,12 @@ FROM microsoft/dotnet:latest
|
|||
RUN apt-get update
|
||||
RUN apt-get install -y build-essential nodejs nodejs-legacy
|
||||
|
||||
COPY . /app
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY project.json .
|
||||
RUN ["dotnet", "restore"]
|
||||
|
||||
COPY . /app
|
||||
RUN ["dotnet", "build"]
|
||||
|
||||
EXPOSE 5000/tcp
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
FROM microsoft/dotnet:latest
|
||||
|
||||
COPY . /app
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY project.json .
|
||||
RUN ["dotnet", "restore"]
|
||||
|
||||
COPY . /app
|
||||
RUN ["dotnet", "build"]
|
||||
|
||||
EXPOSE 5000/tcp
|
||||
|
|
|
|||
Loading…
Reference in New Issue