build: add support .net 10
All checks were successful
Build and Deploy Docker Container / build-and-deploy (push) Successful in 4m33s
All checks were successful
Build and Deploy Docker Container / build-and-deploy (push) Successful in 4m33s
This commit is contained in:
22
Dockerfile
22
Dockerfile
@@ -1,4 +1,4 @@
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:10.0 AS base
|
||||
LABEL company="Winsomnia"
|
||||
LABEL maintainer.name="Wesser" maintainer.email="support@winsomnia.net"
|
||||
WORKDIR /app
|
||||
@@ -7,7 +7,7 @@ RUN apt-get update && apt-get install -y curl && rm -rf /var/lib/apt/lists/*
|
||||
HEALTHCHECK --interval=30s --timeout=10s --start-period=5s --retries=3 \
|
||||
CMD curl --fail http://localhost:8080/health || exit 1
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
|
||||
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
|
||||
WORKDIR /src
|
||||
COPY . .
|
||||
|
||||
@@ -15,15 +15,19 @@ ARG NUGET_USERNAME
|
||||
ARG NUGET_PASSWORD
|
||||
ARG NUGET_ADDRESS
|
||||
|
||||
ENV NUGET_USERNAME=$NUGET_USERNAME
|
||||
ENV NUGET_PASSWORD=$NUGET_PASSWORD
|
||||
ENV NUGET_ADDRESS=$NUGET_ADDRESS
|
||||
RUN dotnet nuget add source ${NUGET_ADDRESS} \
|
||||
--name Winsomnia \
|
||||
--username ${NUGET_USERNAME} \
|
||||
--password ${NUGET_PASSWORD} \
|
||||
--store-password-in-clear-text
|
||||
|
||||
RUN dotnet nuget add source --name="Winsomnia" --username ${NUGET_USERNAME} --store-password-in-clear-text --password ${NUGET_PASSWORD} ${NUGET_ADDRESS}
|
||||
RUN dotnet restore ./Backend.sln
|
||||
WORKDIR /app
|
||||
WORKDIR /src
|
||||
RUN dotnet publish ./Endpoint/Endpoint.csproj -c Release --self-contained false -p:PublishSingleFile=false -o /app
|
||||
|
||||
RUN dotnet publish Endpoint/Endpoint.csproj \
|
||||
-c Release \
|
||||
--self-contained false \
|
||||
-p:PublishSingleFile=false \
|
||||
-o /app
|
||||
|
||||
FROM base AS final
|
||||
WORKDIR /app
|
||||
|
||||
Reference in New Issue
Block a user