From d3af80944cbd14c255e0dbfd0bc755cd3d4199a0 Mon Sep 17 00:00:00 2001 From: Eric Olander Date: Fri, 6 Mar 2020 21:45:31 -0700 Subject: [PATCH] Create Dockerfile and instructions for building using the docker image --- DOCKER.md | 19 +++++++++++++++++++ Dockerfile | 6 ++++++ 2 files changed, 25 insertions(+) create mode 100644 DOCKER.md create mode 100644 Dockerfile diff --git a/DOCKER.md b/DOCKER.md new file mode 100644 index 00000000..9bec879e --- /dev/null +++ b/DOCKER.md @@ -0,0 +1,19 @@ +Building from Docker +-------- + +Create the docker image +```bash +$ docker image build -t milewski-ctfp-pdf:1.0 . +``` + +Run it interactively starting the nix-shell +```bash +$ docker container run -i -t --name ctfp milewski-ctfp-pdf:1.0 nix-shell +``` + +Follow build directions in README.md + +Copy build artifact(s) to local filesystem +```bash +docker cp ctfp:/usr/git/milewski-ctfp-pdf/out/... destfile +``` \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..f79276a0 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,6 @@ +FROM nixorg/nix:latest +ENV NIX_PATH="nixpkgs=https://github.com/NixOS/nixpkgs/archive/release-19.03.tar.gz" +WORKDIR /usr/git +RUN git clone https://github.com/hmemcpy/milewski-ctfp-pdf.git +WORKDIR milewski-ctfp-pdf +RUN nix-shell