Skip to content

Commit

Permalink
fix: update dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
stdevMac committed Oct 4, 2024
1 parent 531d0e0 commit 4d3d8c8
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions nethermind/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ RUN git clone $REPO --branch op-node/$VERSION --single-branch . && \
RUN cd op-node && \
make VERSION=$VERSION op-node

FROM mcr.microsoft.com/dotnet/sdk:8.0-noble AS build
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:8.0-noble AS build

ARG BUILD_CONFIG=release
ARG TARGETARCH
Expand All @@ -25,12 +25,13 @@ ENV COMMIT=7320938e5fe74ad6ac1782ce723ddb7bb7d3d78a
RUN git clone $REPO --branch release/$VERSION --single-branch . && \
git switch -c branch-$VERSION
RUN bash -c '[ "$(git rev-parse HEAD)" = "$COMMIT" ]'
RUN TARGETARCH=${TARGETARCH#linux/} && \
arch=$([ "$TARGETARCH" = "amd64" ] && echo "x64" || echo "$TARGETARCH") && \
echo "Using architecture: $arch" && \
dotnet publish src/Nethermind/Nethermind.Runner -c $BUILD_CONFIG -a $arch -o /publish --sc false

RUN arch=$([ "$TARGETARCH" = "amd64" ] && echo "x64" || echo "$TARGETARCH") && \
dotnet publish src/Nethermind/Nethermind.Runner -c $BUILD_CONFIG -a $arch -o /publish --sc false


FROM mcr.microsoft.com/dotnet/aspnet:8.0-noble
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/aspnet:8.0-noble

RUN apt-get update && \
apt-get install -y jq curl supervisor && \
Expand Down

0 comments on commit 4d3d8c8

Please sign in to comment.