Skip to content
This repository was archived by the owner on Apr 1, 2025. It is now read-only.

Commit 353c99d

Browse files
committed
Add a Dockerfile that builds the CLI tool
1 parent 5e96983 commit 353c99d

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed

.dockerignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Dockerfile

Dockerfile

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
FROM haskell:8.6 as build
2+
WORKDIR /build
3+
RUN cabal new-update
4+
COPY . /build
5+
RUN cabal new-build semantic:exe:semantic
6+
7+
# A fake `install` target until we can get `cabal new-install` to work
8+
RUN cp $(find dist-newstyle -name semantic -type f -perm -u=x) /semantic
9+
10+
FROM debian:stretch
11+
RUN apt-get update && \
12+
apt-get install -y \
13+
libgmp10 \
14+
&& \
15+
apt-get autoremove -y && \
16+
apt-get clean -y && \
17+
rm -rf /var/lib/apt/lists/*
18+
COPY --from=build /semantic /usr/local/bin/semantic
19+
ENTRYPOINT ["/usr/local/bin/semantic"]

0 commit comments

Comments
 (0)