-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
33 lines (23 loc) · 846 Bytes
/
Dockerfile
File metadata and controls
33 lines (23 loc) · 846 Bytes
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
29
30
31
32
33
FROM node:lts AS node_builder
WORKDIR /app
COPY ./FileSystemWeb/ClientApp .
RUN npm install
RUN npm run build
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS builder
WORKDIR /app
COPY ./StdOttLib ./StdOttLib
COPY ./FileSystemCommon ./FileSystemCommon
COPY ./FileSystemWeb ./FileSystemWeb
WORKDIR /app/FileSystemWeb
# install entity framework tools
# RUN dotnet tool install --global --version 5.0.17 dotnet-ef
# ENV PATH $PATH:/root/.dotnet/tools
# RUN cp ./template.db ./auth.db
# RUN dotnet ef database update
COPY --from=node_builder /app/build ./ClientApp/build
RUN dotnet publish "FileSystemWeb.csproj" -p:BuildClientApp=false -c Release -o /app/publish
RUN cp ./template.db /app/publish/auth.db
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS runner
WORKDIR /app
COPY --from=builder /app/publish .
ENTRYPOINT ["dotnet", "FileSystemWeb.dll"]