Modification de l'image
continuous-integration/drone/push Build is failing
Details
continuous-integration/drone/push Build is failing
Details
parent
d42f7acb9f
commit
73e1aed1a0
@ -0,0 +1,30 @@
|
|||||||
|
**/.classpath
|
||||||
|
**/.dockerignore
|
||||||
|
**/.env
|
||||||
|
**/.git
|
||||||
|
**/.gitignore
|
||||||
|
**/.project
|
||||||
|
**/.settings
|
||||||
|
**/.toolstarget
|
||||||
|
**/.vs
|
||||||
|
**/.vscode
|
||||||
|
**/*.*proj.user
|
||||||
|
**/*.dbmdl
|
||||||
|
**/*.jfm
|
||||||
|
**/azds.yaml
|
||||||
|
**/bin
|
||||||
|
**/charts
|
||||||
|
**/docker-compose*
|
||||||
|
**/Dockerfile*
|
||||||
|
**/node_modules
|
||||||
|
**/npm-debug.log
|
||||||
|
**/obj
|
||||||
|
**/secrets.dev.yaml
|
||||||
|
**/values.dev.yaml
|
||||||
|
LICENSE
|
||||||
|
README.md
|
||||||
|
!**/.gitignore
|
||||||
|
!.git/HEAD
|
||||||
|
!.git/config
|
||||||
|
!.git/packed-refs
|
||||||
|
!.git/refs/heads/**
|
@ -0,0 +1,30 @@
|
|||||||
|
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base
|
||||||
|
USER app
|
||||||
|
WORKDIR /app
|
||||||
|
EXPOSE 8080
|
||||||
|
EXPOSE 8081
|
||||||
|
|
||||||
|
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
|
||||||
|
ARG BUILD_CONFIGURATION=Release
|
||||||
|
WORKDIR /src
|
||||||
|
COPY ["API/API.csproj", "API/"]
|
||||||
|
COPY ["DbContextLib/DbContextLib.csproj", "DbContextLib/"]
|
||||||
|
COPY ["EntityFramework/Entities.csproj", "EntityFramework/"]
|
||||||
|
COPY ["Dto/Dto.csproj", "Dto/"]
|
||||||
|
COPY ["DbDataManager/DbDataManager.csproj", "DbDataManager/"]
|
||||||
|
COPY ["Model/Model.csproj", "Model/"]
|
||||||
|
COPY ["Shared/Shared.csproj", "Shared/"]
|
||||||
|
COPY ["StubbedContextLib/StubbedContextLib.csproj", "StubbedContextLib/"]
|
||||||
|
RUN dotnet restore "./API/./API.csproj"
|
||||||
|
COPY . .
|
||||||
|
WORKDIR "/src/API"
|
||||||
|
RUN dotnet build "./API.csproj" -c $BUILD_CONFIGURATION -o /app/build
|
||||||
|
|
||||||
|
FROM build AS publish
|
||||||
|
ARG BUILD_CONFIGURATION=Release
|
||||||
|
RUN dotnet publish "./API.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p:UseAppHost=false
|
||||||
|
|
||||||
|
FROM base AS final
|
||||||
|
WORKDIR /app
|
||||||
|
COPY --from=publish /app/publish .
|
||||||
|
ENTRYPOINT ["dotnet", "API.dll"]
|
@ -1 +0,0 @@
|
|||||||
**/*Test*.csproj
|
|
@ -1,15 +0,0 @@
|
|||||||
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
|
|
||||||
WORKDIR /app
|
|
||||||
COPY API_SQLuedo/ ./
|
|
||||||
|
|
||||||
# Restore dependencies
|
|
||||||
RUN dotnet restore API/API.csproj
|
|
||||||
|
|
||||||
# Publish the application
|
|
||||||
RUN dotnet publish API/API.csproj -c Release -o /app/publish
|
|
||||||
|
|
||||||
# Final image
|
|
||||||
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base
|
|
||||||
WORKDIR /app
|
|
||||||
COPY --from=build /app/publish .
|
|
||||||
ENTRYPOINT ["dotnet", "./API.dll"]
|
|
Loading…
Reference in new issue