Skip to content

Commit

Permalink
ci: linux: update to GHC 9.4.7
Browse files Browse the repository at this point in the history
  • Loading branch information
elopez committed Oct 24, 2023
1 parent b91be36 commit d8fb998
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 3 deletions.
49 changes: 47 additions & 2 deletions .github/container-linux-static/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,47 @@
FROM ghcr.io/fpco/alpine-haskell-stack:9.4.5
FROM alpine:3.18.4
# Based on https://github.com/fpco/alpine-haskell-stack/blob/9.2.8v2/ghc-Dockerfile

RUN apk upgrade --no-cache &&\
apk add --no-cache \
curl \
gcc \
git \
libc-dev \
xz \
gmp-dev \
autoconf \
automake \
binutils \
build-base \
coreutils \
cpio \
linux-headers \
libffi-dev \
musl-dev \
zlib-dev \
zlib-static \
ncurses-dev \
ncurses-libs \
ncurses-static \
bash \
lld \
shadow # for stack --docker, provides groupadd

RUN curl -sSLo /usr/local/bin/stack https://github.com/commercialhaskell/stack/releases/download/v2.13.1/stack-2.13.1-linux-x86_64-bin && \
chmod +x /usr/local/bin/stack

# https://stackoverflow.com/a/41517423
RUN ln -s /usr/lib/libncurses.a /usr/lib/libtinfo.a

COPY stack-config.yaml /root/.stack/config.yaml

RUN cd /tmp && \
curl -sSLo /tmp/ghc.tar.xz https://downloads.haskell.org/~ghc/9.4.7/ghc-9.4.7-x86_64-alpine3_12-linux.tar.xz && \
tar xf ghc.tar.xz && \
cd ghc-9.4.7-x86_64-unknown-linux && \
./configure --prefix=/usr/local && \
make install && \
rm -rf /tmp/ghc.tar.xz /tmp/ghc-9.4.7-x86_64-unknown-linux

RUN apk upgrade --no-cache &&\
apk add --no-cache \
Expand Down Expand Up @@ -26,4 +69,6 @@ RUN mkdir -p /etc/stack &&\
echo "system-ghc: true" ;\
echo "install-ghc: false" ;\
echo "skip-ghc-check: true" ;\
} >> /etc/stack/config.yaml
} >> /etc/stack/config.yaml &&\
chmod 664 /etc/stack/config.yaml &&\
chown root:runneruser /etc/stack/config.yaml
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
include:
- os: ubuntu-20.04
shell: bash
container: "{\"image\": \"elopeztob/alpine-haskell-stack-echidna:9.4.5\", \"options\": \"--user 1001\"}"
container: "{\"image\": \"elopeztob/alpine-haskell-stack-echidna:ghc-9.4.7\", \"options\": \"--user 1001\"}"
- os: macos-latest
shell: bash
- os: windows-latest
Expand Down

0 comments on commit d8fb998

Please sign in to comment.