Skip to content
This repository was archived by the owner on Sep 5, 2022. It is now read-only.

Commit ed5608b

Browse files
authored
Merge pull request #13 from mukaschultze/docker
Dockerfiles improvements
2 parents c8a2063 + 2b3e52d commit ed5608b

File tree

3 files changed

+12
-15
lines changed

3 files changed

+12
-15
lines changed
Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,15 @@
11
FROM mcr.microsoft.com/dotnet/sdk:5.0-alpine AS builder
2-
WORKDIR /lrm
2+
WORKDIR /lrm-lb
33
COPY . .
4-
RUN [\
5-
"dotnet", "publish", \
6-
"--output", "/build/", \
7-
"--configuration", "Release",\
8-
"--no-self-contained", \
9-
"." ]
4+
ARG BUILD_MODE="Release"
5+
RUN dotnet publish \
6+
--output /build/ \
7+
--configuration $BUILD_MODE \
8+
--no-self-contained .
109

1110
FROM mcr.microsoft.com/dotnet/runtime:5.0-alpine
1211
WORKDIR /lrm-lb
1312
COPY --from=builder /build/ .
1413
ENV LRM_LB_CONFIG_PATH="/config/config-load-balancer.json"
1514
CMD [ "./LRM_LoadBalancer" ]
16-
ENTRYPOINT [ "./LRM_LoadBalancer" ]
15+
ENTRYPOINT [ "./LRM_LoadBalancer"]
Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,15 @@
11
FROM mcr.microsoft.com/dotnet/sdk:5.0-alpine AS builder
22
WORKDIR /lrm
33
COPY . .
4-
RUN [\
5-
"dotnet", "publish", \
6-
"--output", "/build/", \
7-
"--configuration", "Release",\
8-
"--no-self-contained", \
9-
"." ]
4+
ARG BUILD_MODE="Release"
5+
RUN dotnet publish \
6+
--output /build/ \
7+
--configuration $BUILD_MODE \
8+
--no-self-contained .
109

1110
FROM mcr.microsoft.com/dotnet/runtime:5.0-alpine
1211
WORKDIR /lrm
1312
COPY --from=builder /build/ .
14-
COPY ./MultiCompiled.dll .
1513
ENV LRM_CONFIG_PATH="/config/config.json"
1614
CMD [ "./LRM" ]
1715
ENTRYPOINT [ "./LRM" ]
-79 KB
Binary file not shown.

0 commit comments

Comments
 (0)