From 19559fe2138002455ed6c24a7e61fadfda0c1a09 Mon Sep 17 00:00:00 2001 From: Mayank Rathee <mayankrathee.japan@gmail.com> Date: Mon, 15 Jun 2020 12:33:06 +0530 Subject: [PATCH] Dockerfile updated. Running fine. --- EzPC/Docker/Dockerfile | 60 ++++++++++++++++++------ EzPC/Docker/run_docker_example_client.sh | 0 EzPC/Docker/run_docker_example_server.sh | 0 3 files changed, 46 insertions(+), 14 deletions(-) mode change 100644 => 100755 EzPC/Docker/run_docker_example_client.sh mode change 100644 => 100755 EzPC/Docker/run_docker_example_server.sh diff --git a/EzPC/Docker/Dockerfile b/EzPC/Docker/Dockerfile index 1de8f05..b6d0db1 100644 --- a/EzPC/Docker/Dockerfile +++ b/EzPC/Docker/Dockerfile @@ -27,12 +27,23 @@ RUN apt-get install -y gcc RUN apt-get install -y wget git-core RUN apt-get install -y git RUN apt-get install -y g++ -RUN apt-get install -y cmake +RUN DEBIAN_FRONTEND="noninteractive" apt-get -y install cmake RUN apt-get install -y libgmp-dev RUN apt-get install -y libssl-dev RUN apt-get install -y vim RUN apt-get install -y libglib2.0-dev RUN apt-get install -y ocaml +RUN apt-get install -y python3 +RUN apt-get update +RUN apt-get install -y python3-pip +RUN pip3 install numpy +RUN pip3 install scipy +RUN pip3 install pandas +RUN pip3 install scikit-learn +RUN pip3 install ipython +RUN pip3 install matplotlib +RUN apt-get install -y graphviz + #Get opam RUN apt-get install -y opam @@ -46,16 +57,31 @@ RUN cp /usr/lib/x86_64-linux-gnu/libcrypto.so.1.1 /usr/local/lib/libcrypto.so.1. #Clone latest ABY installation scripts and install ABY RUN git clone https://github.com/mayank0403/ABY-Installation-Scripts -RUN cd ABY-Installation-Scripts && git checkout docker +RUN cd ABY-Installation-Scripts && git checkout docker && git pull origin docker RUN mkdir ABY-latest RUN cp ABY-Installation-Scripts/* ABY-latest/. WORKDIR /ezpc-workdir/ABY-latest RUN ["bash", "install.sh"] RUN ["bash", "install-cmake.sh"] -RUN ["bash", "install-after-cmake-check.sh"] +#RUN ["bash", "install-after-cmake-check.sh"] #To stick to a commit that works in ABY +RUN cd ../ABY-Installation-Scripts && git pull +RUN cp ../ABY-Installation-Scripts/* . + WORKDIR /ezpc-workdir/ABY-latest/ABY -RUN git checkout -b docker_specific_branch 8aa003c2e145c6d43b6ec73ef75618be43951b1d +RUN git submodule update --init --recursive +RUN git checkout 8aa003c2e145c6d43b6ec73ef75618be43951b1d +RUN git checkout 08baa853de76a9070cb8ed8d41e96569776e4773 -- CMakeLists.txt +RUN git checkout -b docker_specific_branch +RUN cd extern/ENCRYPTO_utils/ && git checkout 11cd5efa9be6d506c967d6e6835fa239e47c7207 +#WORKDIR /ezpc-workdir/ABY-latest +#RUN ["bash", "install-after-cmake-check.sh"] +WORKDIR /ezpc-workdir/ABY-latest/ABY +RUN cd extern/OTExtension/ && git checkout e4bcb68f9e7eb8753bc6a6ab1c2e3b70ad40e54f +WORKDIR /ezpc-workdir/ABY-latest +RUN ["bash", "install-after-cmake-check.sh"] +WORKDIR /ezpc-workdir/ABY-latest/ABY + #29th April 2019 commit #RUN git checkout -b docker_specific_branch d4ca22996967ba076b6ca378e231d72f9c35cf51 #Add docker-test dir and copy ezpc.h and other files @@ -64,22 +90,28 @@ RUN cd src/examples/ && mkdir docker-test && echo "add_subdirectory(docker-test) #Pull EzPC source from GitHub. WORKDIR /ezpc-workdir RUN git clone https://github.com/mpc-msri/EzPC +RUN cd EzPC && git checkout random_forest WORKDIR /ezpc-workdir/ABY-latest/ABY -RUN cd src/examples/docker-test && cp -r ../../../../../EzPC/EzPC/ABY_example/* . +RUN cd src/examples/docker-test && cp -r ../../../../../EzPC/EzPC/EzPC/ABY_example/* . -WORKDIR /ezpc-workdir/EzPC -RUN git checkout -b docker_specific_branch c8b45fd28fb41c46d3054f4fbe7c1b0dddb87ccd +WORKDIR /ezpc-workdir/EzPC/EzPC/EzPC +#RUN git checkout -b docker_specific_branch c8b45fd28fb41c46d3054f4fbe7c1b0dddb87ccd #EzPC specific ocaml packages -RUN opam init +RUN opam init --disable-sandboxing +RUN opam switch create 4.06.1 RUN opam switch 4.06.1 -RUN eval $(opam config env) && \ - opam depext conf-m4.1 && \ +RUN opam install -y depext +RUN eval $(opam env) && \ + `opam depext conf-m4.1` && \ opam install -y ocamlbuild && \ opam install -y Stdint && \ - opam install -y menhir && \ - cd EzPC && \ - make -RUN echo 'eval "$(opam config env)"' >> /root/.bashrc + opam install -y menhir + +RUN git fetch && git pull +RUN git checkout -b docker_specific_branch 8896358f139c5bf0c7c9519c69e259d56e094914 +RUN eval $(opam env) && make +RUN echo 'eval "$(opam env)"' >> /root/.bashrc +WORKDIR /ezpc-workdir/EzPC/EzPC diff --git a/EzPC/Docker/run_docker_example_client.sh b/EzPC/Docker/run_docker_example_client.sh old mode 100644 new mode 100755 diff --git a/EzPC/Docker/run_docker_example_server.sh b/EzPC/Docker/run_docker_example_server.sh old mode 100644 new mode 100755 -- GitLab