Update docker build
This commit is contained in:
parent
8def5e28a4
commit
ce9be45e8f
@ -6,3 +6,4 @@ Dockerfile
|
||||
.dockerignore
|
||||
docker-build.sh
|
||||
.vs/
|
||||
.idea/
|
||||
|
@ -2,11 +2,11 @@ FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:8.0-preview AS build
|
||||
ARG TARGETARCH
|
||||
WORKDIR /build
|
||||
COPY Pal.Common/Pal.Common.csproj Pal.Common/
|
||||
COPY Pal.Server/Pal.Server.csproj Pal.Server/
|
||||
RUN dotnet restore Pal.Server/Pal.Server.csproj -a $TARGETARCH
|
||||
COPY Server/Server/Pal.Server.csproj Pal.Server/
|
||||
RUN dotnet restore Server/Server/Pal.Server.csproj -a $TARGETARCH
|
||||
|
||||
COPY . ./
|
||||
RUN dotnet publish Pal.Server/Pal.Server.csproj -a $TARGETARCH --no-restore -o /dist
|
||||
RUN dotnet publish Server/Server/Pal.Server.csproj -a $TARGETARCH --no-restore -o /dist
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/aspnet:8.0-preview
|
||||
|
||||
@ -27,4 +27,4 @@ WORKDIR /app
|
||||
COPY --from=build-env /dist .
|
||||
|
||||
USER pal
|
||||
ENTRYPOINT ["dotnet", "Pal.Server.dll"]
|
||||
ENTRYPOINT ["dotnet", "Pal.Server.dll"]
|
||||
|
@ -1,3 +1,4 @@
|
||||
git fetch origin master
|
||||
git reset --hard origin/master
|
||||
git submodule update --checkout
|
||||
docker buildx build -t palacepal-server --platform linux/amd64,linux/arm64 .
|
||||
|
Loading…
Reference in New Issue
Block a user