Last active
May 7, 2017 07:32
-
-
Save ariesshrimp/038fe86e9c5128386d4f144f1d31c7f3 to your computer and use it in GitHub Desktop.
A Dockerfile for working through Real World Ocaml https://github.com/realworldocaml/book
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# See https://hub.docker.com/r/ocaml/opam/ | |
FROM ocaml/opam | |
# Get core set up | |
RUN opam depext -i core | |
# Do some extra stuff to make cryptokit happy | |
RUN opam depext conf-zlib.1 && opam depext conf-gmp.1 && opam install cryptokit | |
# Install all the packages the book uses, including the utop REPL | |
RUN opam install utop async yojson core_extended core_bench cohttp async_graphics menhir | |
# Tell utop how to boot up with all the important functions you want | |
RUN echo '#use "topfind";; #thread;; #camlp4o;; #require "core.top";; #require "core.syntax";; open Core.Std' > ~/.ocamlinit |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
To get started:
I also recommend mounting a local directory where you can write all your fancy new Ocaml in your preferred editor, but give Docker access to them to build and run: