mirror of
https://github.com/azaion/flights.git
synced 2026-04-22 08:46:32 +00:00
37bee961ab
- Modify Dockerfile to support multi-platform builds using TARGETARCH. - Update coderule.mdc to enforce source code organization under the `src/` directory. - Remove outdated rule from python.mdc regarding `src/` layout.
13 lines
391 B
Docker
13 lines
391 B
Docker
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:10.0 AS build
|
|
ARG TARGETARCH
|
|
WORKDIR /src
|
|
COPY . .
|
|
RUN arch=$([ "$TARGETARCH" = "amd64" ] && echo "x64" || echo "$TARGETARCH") && \
|
|
dotnet publish -c Release -o /app --os linux --arch $arch
|
|
|
|
FROM mcr.microsoft.com/dotnet/aspnet:10.0
|
|
WORKDIR /app
|
|
COPY --from=build /app .
|
|
EXPOSE 8080
|
|
ENTRYPOINT ["dotnet", "Azaion.Flights.dll"]
|