stitch
Note taking for messy minimalists
git clone git://mccd.space/stitch| Log | Files | Refs | README | LICENSE | Mail |
Dockerfile (870B)
1 FROM alpine:edge AS builder
2
3 # Install the build dependencies
4 RUN apk add --no-cache make m4 which patch sudo wget git pkgconfig \
5 gcc g++ musl-dev linux-headers libffi libffi-dev pcre perl python3 \
6 gmp-dev pcre-dev xz-dev gmp xz coreutils \
7 ocaml ocaml-compiler-libs ocaml-ocamldoc opam ocaml-findlib openssh rsync
8 RUN chmod +s `which bwrap`
9
10 RUN addgroup -g 1000 -S ocaml && adduser -u 1000 -D -S ocaml -G ocaml
11 USER ocaml
12 WORKDIR /home/ocaml
13
14 RUN opam init --auto-setup --disable-sandboxing --yes -c 4.14.2 --keep-build-dir
15 RUN eval `opam env --switch=4.14.2`
16
17 RUN opam install --yes dune && eval `opam env --switch=4.14.2`
18
19 COPY --chown=ocaml:ocaml stitch.opam /tmp/build/
20 WORKDIR /tmp/build
21 RUN git config --global --add safe.directory /tmp/build
22
23 RUN opam install . --update-invariant --yes
24 COPY . .
25 CMD eval `opam env` && dune build --profile release-static