Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update arm64.Dockerfile #5847

Merged
merged 1 commit into from
Aug 30, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 15 additions & 6 deletions etc/dockerfiles/arm64.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,27 @@ RUN curl -sSL https://github.com/commercialhaskell/stack/releases/download/v2.7.
ARG USERID
ARG GROUPID

RUN useradd --uid $USERID stack && mkdir -p /home/stack && chown -R stack /home/stack && usermod -aG $GROUPID stack
RUN useradd --uid $USERID stack
RUN mkdir -p /home/stack
RUN chown -R stack /home/stack
RUN usermod -aG $GROUPID stack

USER stack
WORKDIR /home/stack

RUN stack setup ghc-8.10.4
RUN stack update

COPY stack.yaml package.yaml /src/

USER root

RUN chown -R stack /src

USER stack
RUN cd /src && stack build --only-snapshot --test && stack build shake
WORKDIR /src

RUN stack build --only-snapshot --test
RUN stack build shake

COPY etc/scripts/release.hs /src
RUN stack script --resolver lts-17.15 --compile /src/release.hs -- --version && cp /src/release /home/stack

RUN stack script --resolver nightly-2022-08-02 --extra-dep Cabal-3.6.3.0 --compile /src/release.hs -- --version
RUN cp /src/release /home/stack