Try out a Docker build

This commit is contained in:
Michael Snoyman 2015-01-06 11:33:44 +02:00
parent e77403edc4
commit 44cba232b7
3 changed files with 38 additions and 4 deletions

7
.dockerignore Normal file
View File

@ -0,0 +1,7 @@
dist
builds
logs
.cabal-sandbox
cabal.sandbox.config
tarballs
*.yaml

27
Dockerfile Normal file
View File

@ -0,0 +1,27 @@
FROM ubuntu:12.04
ENV HOME /home/stackage
ENV LANG en_US.UTF-8
RUN mkdir /home/stackage -p
RUN locale-gen en_US.UTF-8
RUN DEBIAN_FRONTEND=noninteractive apt-get update
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y software-properties-common python-software-properties
RUN DEBIAN_FRONTEND=noninteractive add-apt-repository ppa:hvr/ghc -y
ADD debian-bootstrap.sh /tmp/debian-bootstrap.sh
RUN DEBIAN_FRONTEND=noninteractive bash /tmp/debian-bootstrap.sh
RUN rm /tmp/debian-bootstrap.sh
RUN DEBIAN_FRONTEND=noninteractive apt-get install -y cabal-install-1.20 ghc-7.8.4
ENV PATH /opt/ghc/7.8.4/bin:/opt/cabal/1.20/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
RUN cabal update
ADD . /tmp/stackage
RUN cd /tmp/stackage && cabal install
RUN cp $HOME/.cabal/bin/stackage /usr/local/bin
RUN rm -rf $HOME/.cabal $HOME/.ghc /tmp/stackage
RUN cd /home/stackage && cabal update && stackage nightly

View File

@ -10,10 +10,10 @@
# instructions, see:
# http://www.stackage.org/install
sudo add-apt-repository -y ppa:chris-lea/zeromq
sudo add-apt-repository -y ppa:floe/libtisch
sudo apt-get update
sudo apt-get install -y \
add-apt-repository -y ppa:chris-lea/zeromq
add-apt-repository -y ppa:floe/libtisch
apt-get update
apt-get install -y \
build-essential \
libncurses-dev \
git \