diff --git a/Dockerfile b/Dockerfile index 5630305a..931c544f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ FROM ocaml/opam:debian-10-ocaml-4.12@sha256:9ce3fcbb65b4a23c56445d5c15e5009a37e904f0306586bbee57f8791a99f58c AS build RUN sudo apt-get update && sudo apt-get install libev-dev capnproto m4 pkg-config libsqlite3-dev libgmp-dev -y --no-install-recommends -RUN cd ~/opam-repository && git pull origin -q master && git reset --hard 5247d732ce1392a737ff162ee69f674b10a0e6a4 && opam update +RUN cd ~/opam-repository && git pull origin -q master && git reset --hard 9935f57dd3f9722e6ca803aeb232b49d7058abf8 && opam update COPY --chown=opam ocluster-api.opam ocluster.opam /src/ COPY --chown=opam obuilder/obuilder.opam obuilder/obuilder-spec.opam /src/obuilder/ RUN opam pin -yn /src/obuilder/ diff --git a/Dockerfile.worker b/Dockerfile.worker index 607884f7..9989b6c7 100644 --- a/Dockerfile.worker +++ b/Dockerfile.worker @@ -1,6 +1,6 @@ FROM ocaml/opam:debian-10-ocaml-4.12@sha256:9ce3fcbb65b4a23c56445d5c15e5009a37e904f0306586bbee57f8791a99f58c AS build RUN sudo apt-get update && sudo apt-get install libev-dev capnproto m4 pkg-config libsqlite3-dev libgmp-dev -y --no-install-recommends -RUN cd ~/opam-repository && git pull origin -q master && git reset --hard 5247d732ce1392a737ff162ee69f674b10a0e6a4 && opam update +RUN cd ~/opam-repository && git pull origin -q master && git reset --hard 9935f57dd3f9722e6ca803aeb232b49d7058abf8 && opam update COPY --chown=opam ocluster-api.opam ocluster.opam /src/ COPY --chown=opam obuilder/obuilder.opam obuilder/obuilder-spec.opam /src/obuilder/ RUN opam pin -yn /src/obuilder/ @@ -9,20 +9,9 @@ RUN opam install -y --deps-only . ADD --chown=opam . . RUN opam config exec -- dune build ./_build/install/default/bin/ocluster-worker -FROM golang:1.15-buster AS runc -RUN apt-get update && apt-get -y install libseccomp-dev -RUN wget https://github.com/opencontainers/runc/archive/v1.0.0-rc92.tar.gz -RUN mkdir -p github.com/opencontainers -RUN tar xf v1.0.0-rc92.tar.gz -C github.com/opencontainers -RUN mv github.com/opencontainers/runc-* github.com/opencontainers/runc -WORKDIR github.com/opencontainers/runc -RUN make -RUN make install - FROM debian:10 RUN apt-get update && apt-get install docker.io libev4 curl gnupg2 git libsqlite3-dev ca-certificates netbase -y --no-install-recommends WORKDIR /var/lib/ocluster-worker ENTRYPOINT ["/usr/local/bin/ocluster-worker"] ENV PROGRESS_NO_TRUNC=1 COPY --from=build /src/_build/install/default/bin/ocluster-worker /usr/local/bin/ -COPY --from=runc /usr/local/sbin/runc /usr/local/bin/