[commit: packages/binary] master: Add docker-compose.yml to run tests on multiple ghc versions. (cb84b16)
git at git.haskell.org
git at git.haskell.org
Sun Oct 7 22:34:56 UTC 2018
Repository : ssh://git@git.haskell.org/binary
On branch : master
Link : http://git.haskell.org/packages/binary.git/commitdiff/cb84b16a309f7f9bb0feb849776e57da8ed8548a
>---------------------------------------------------------------
commit cb84b16a309f7f9bb0feb849776e57da8ed8548a
Author: Lennart Kolmodin <kolmodin at gmail.com>
Date: Wed Aug 8 12:42:58 2018 +0000
Add docker-compose.yml to run tests on multiple ghc versions.
>---------------------------------------------------------------
cb84b16a309f7f9bb0feb849776e57da8ed8548a
docker-compose.yml | 68 +++++++++++++++++++++++++
docker/{Dockerfile.ghc843 => Dockerfile.anyghc} | 12 +++--
docker/Dockerfile.ghc843 | 2 +-
3 files changed, 78 insertions(+), 4 deletions(-)
diff --git a/docker-compose.yml b/docker-compose.yml
new file mode 100644
index 0000000..1931631
--- /dev/null
+++ b/docker-compose.yml
@@ -0,0 +1,68 @@
+version: '3'
+services:
+ binary_ghc843:
+ build:
+ context: .
+ dockerfile: docker/Dockerfile.ghc843
+ args:
+ - ghcver=8.4.3
+ volumes:
+ - cabal-store-cache:/root/.cabal/store
+
+ binary_ghc822:
+ build:
+ context: .
+ dockerfile: docker/Dockerfile.anyghc
+ args:
+ - ghcver=8.2.2
+ volumes:
+ - cabal-store-cache:/root/.cabal/store
+
+ binary_ghc802:
+ build:
+ context: .
+ dockerfile: docker/Dockerfile.anyghc
+ args:
+ - ghcver=8.0.2
+ volumes:
+ - cabal-store-cache:/root/.cabal/store
+
+ binary_ghc7103:
+ build:
+ context: .
+ dockerfile: docker/Dockerfile.anyghc
+ args:
+ - ghcver=7.10.3
+ volumes:
+ - cabal-store-cache:/root/.cabal/store
+
+ binary_ghc784:
+ build:
+ context: .
+ dockerfile: docker/Dockerfile.anyghc
+ args:
+ - ghcver=7.8.4
+ volumes:
+ - cabal-store-cache:/root/.cabal/store
+
+ binary_ghc763:
+ build:
+ context: .
+ dockerfile: docker/Dockerfile.anyghc
+ args:
+ - ghcver=7.6.3
+ volumes:
+ - cabal-store-cache:/root/.cabal/store
+
+ binary_ghc742:
+ build:
+ context: .
+ dockerfile: docker/Dockerfile.anyghc
+ args:
+ - ghcver=7.4.2
+ volumes:
+ - cabal-store-cache:/root/.cabal/store
+
+volumes:
+ cabal-store-cache:
+ driver: local
diff --git a/docker/Dockerfile.ghc843 b/docker/Dockerfile.anyghc
similarity index 94%
copy from docker/Dockerfile.ghc843
copy to docker/Dockerfile.anyghc
index 6b84c00..d241ca7 100644
--- a/docker/Dockerfile.ghc843
+++ b/docker/Dockerfile.anyghc
@@ -12,7 +12,11 @@
#
# How to build:
#
-# docker build -f docker/Dockerfile.ghc843 -t haskell/binary .
+# docker build \
+# -f docker/Dockerfile.ghc843 \
+# -t haskell/binary \
+# --build-arg ghcver=8.4.2 \
+# .
#
# How to run (caching the cabal store directory), default is 'cabal new-test':
#
@@ -52,7 +56,7 @@
FROM debian:stable
-# setup locale, US English with UTF-8.
+# setup locale.
# not setting a locale will make some apps fail when outputting utf8.
RUN apt-get update && \
apt-get install -y locales && \
@@ -69,8 +73,10 @@ RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys BA3CBA3FFE22B574
# add haskell repo for debian
RUN echo "deb http://downloads.haskell.org/debian stretch main" > /etc/apt/sources.list.d/haskell.list
+ARG ghcver=8.4.3
+
RUN apt update && apt install -y cabal-install-2.2
-RUN apt update && apt install -y ghc-8.4.3
+RUN apt update && apt install -y ghc-$ghcver
RUN apt update && apt-get install -y zlib1g-dev
ENV PATH=/opt/ghc/bin:$PATH
diff --git a/docker/Dockerfile.ghc843 b/docker/Dockerfile.ghc843
index 6b84c00..e704d99 100644
--- a/docker/Dockerfile.ghc843
+++ b/docker/Dockerfile.ghc843
@@ -52,7 +52,7 @@
FROM debian:stable
-# setup locale, US English with UTF-8.
+# setup locale.
# not setting a locale will make some apps fail when outputting utf8.
RUN apt-get update && \
apt-get install -y locales && \
More information about the ghc-commits
mailing list