Skip to content

Commit 567bf39

Browse files
committed
adding docker file
1 parent dc78fda commit 567bf39

File tree

2 files changed

+29
-0
lines changed

2 files changed

+29
-0
lines changed

Dockerfile

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
FROM ubuntu:16.04
2+
3+
WORKDIR /root
4+
5+
RUN apt-get update && \
6+
apt-get install -y \
7+
wget unzip curl \
8+
build-essential cmake git libgmp3-dev libprocps4-dev python-markdown libboost-all-dev libssl-dev pkg-config
9+
10+
RUN git clone https://github.com/scipr-lab/libsnark/ \
11+
&& cd libsnark \
12+
&& git submodule init && git submodule update \
13+
&& mkdir build && cd build && cmake .. \
14+
&& make \
15+
&& DESTDIR=/usr/local make install \
16+
NO_PROCPS=1 NO_GTEST=1 NO_DOCS=1 CURVE=ALT_BN128 FEATUREFLAGS="-DBINARY_OUTPUT=1 -DMONTGOMERY_OUTPUT=1 -DNO_PT_COMPRESSION=1"
17+
18+
ENV LD_LIBRARY_PATH $LD_LIBRARY_PATH:/usr/local/lib

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -408,6 +408,17 @@ to control these (you can see the default at the top of CMakeLists.txt).
408408

409409
Not all combinations are tested together or supported by every part of the codebase.
410410

411+
--------------------------------------------------------------------------------
412+
Docker
413+
--------------------------------------------------------------------------------
414+
415+
You can run `libsnark` on Docker:
416+
417+
```
418+
$ docker build -t libsnark .
419+
$ docker run -ti libsnark /bin/bash
420+
```
421+
411422

412423
--------------------------------------------------------------------------------
413424
Tutorials

0 commit comments

Comments
 (0)