modify dockerfile to build for arm64 servers

This commit is contained in:
Siddhartha 2022-09-21 03:41:43 +00:00
parent 180b4b9dcb
commit 7e55334e04
1 changed files with 3 additions and 3 deletions

View File

@ -4,10 +4,10 @@ FROM ubuntu:focal AS build
### Build stage
# Install curl and git and smp-related dependencies
RUN apt-get update && apt-get install -y curl git build-essential libgmp3-dev zlib1g-dev
RUN apt-get update && apt-get install -y curl git build-essential libgmp3-dev zlib1g-dev libnuma1 libnuma-dev llvm
# Install ghcup
RUN curl https://downloads.haskell.org/~ghcup/x86_64-linux-ghcup -o /usr/bin/ghcup && \
RUN curl https://downloads.haskell.org/~ghcup/aarch64-linux-ghcup -o /usr/bin/ghcup && \
chmod +x /usr/bin/ghcup
# Install ghc
@ -35,7 +35,7 @@ RUN cabal install
FROM final
# Install OpenSSL dependency
RUN apt-get update && apt-get install -y openssl
RUN apt-get update && apt-get install -y openssl libnuma1 libnuma-dev
# Copy compiled smp-server from build stage
COPY --from=build /root/.cabal/bin/smp-server /usr/bin/smp-server