-
Notifications
You must be signed in to change notification settings - Fork 186
/
Copy pathDockerfile
54 lines (42 loc) · 1.19 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
FROM ubuntu:16.04
## ensure locale is set during build
ENV LANG C.UTF-8
## Haskell environment
RUN echo 'deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main' > \
/etc/apt/sources.list.d/ghc.list && \
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys F6F88286 && \
apt-get update && \
apt-get install -y --no-install-recommends \
cabal-install-2.2 \
ghc-8.4.2 \
happy-1.19.5 \
alex-3.1.7 \
zlib1g-dev \
libtinfo-dev \
libsqlite3-0 \
libsqlite3-dev \
ca-certificates \
build-essential \
libgmp-dev \
autoconf \
automake \
curl \
g++ \
python3 \
git
ENV PATH /root/.cabal/bin:/root/.local/bin:/opt/cabal/bin:/opt/ghc/8.4.2/bin:/opt/happy/1.19.5/bin:/opt/alex/3.1.7/bin:$PATH
## node.js
RUN curl -sL https://deb.nodesource.com/setup_8.x | bash - \
&& apt-get install -y nodejs
## build GHCJS
WORKDIR /opt
RUN cabal update
ADD . ./ghcjs
RUN cd /opt/ghcjs && \
./utils/makePackages.sh && \
./utils/makeSandbox.sh && \
cabal install
ENV PATH /opt/ghcjs/.cabal-sandbox/bin:$PATH
RUN cd /opt/ghcjs && \
ghcjs-boot -v2 -s ./lib/boot/
ENTRYPOINT ["ghcjs"]