File tree Expand file tree Collapse file tree 2 files changed +12
-9
lines changed
frameworks/CSharp/wiredio Expand file tree Collapse file tree 2 files changed +12
-9
lines changed Original file line number Diff line number Diff line change 1- FROM mcr.microsoft.com/dotnet/sdk:9.0 AS build
2- RUN apt-get update && apt-get install -y --no-install-recommends clang lld zlib1g-dev && rm -rf /var/lib/apt/lists/*
1+ # Build
2+ FROM mcr.microsoft.com/dotnet/sdk:9.0-alpine AS build
3+ RUN apk add --no-cache clang build-base zlib-dev linux-headers
34WORKDIR /src
45COPY src/Platform/ ./Platform/
56WORKDIR /src/Platform
67RUN dotnet publish -c Release \
7- -r linux-x64 \
8+ -r linux-musl- x64 \
89 --self-contained true \
910 -p:PublishAot=true \
1011 -p:OptimizationPreference=Speed \
1112 -p:GarbageCollectionAdaptationMode=0 \
1213 -o /app/out
1314
14- FROM mcr.microsoft.com/dotnet/runtime-deps:9.0
15+ # Runtime (musl)
16+ FROM mcr.microsoft.com/dotnet/runtime-deps:9.0-alpine
1517ENV URLS=http://+:8080
1618WORKDIR /app
1719COPY --from=build /app/out ./
1820RUN chmod +x ./Platform
1921EXPOSE 8080
2022ENTRYPOINT ["./Platform" ]
21-
Original file line number Diff line number Diff line change 1- FROM mcr.microsoft.com/dotnet/sdk:9.0 AS build
2- RUN apt-get update && apt-get install -y --no-install-recommends clang lld zlib1g-dev && rm -rf /var/lib/apt/lists/*
1+ # Build
2+ FROM mcr.microsoft.com/dotnet/sdk:9.0-alpine AS build
3+ RUN apk add --no-cache clang build-base zlib-dev linux-headers
34WORKDIR /src
45COPY src/Fullstack/ ./Fullstack/
56WORKDIR /src/Fullstack
67RUN dotnet publish -c Release \
7- -r linux-x64 \
8+ -r linux-musl- x64 \
89 --self-contained true \
910 -p:PublishAot=true \
1011 -p:OptimizationPreference=Speed \
1112 -p:GarbageCollectionAdaptationMode=0 \
1213 -o /app/out
1314
14- FROM mcr.microsoft.com/dotnet/runtime-deps:9.0
15+ # Runtime (musl)
16+ FROM mcr.microsoft.com/dotnet/runtime-deps:9.0-alpine
1517ENV URLS=http://+:8080
1618WORKDIR /app
1719COPY --from=build /app/out ./
You can’t perform that action at this time.
0 commit comments