-
Notifications
You must be signed in to change notification settings - Fork 24
/
Dockerfile
47 lines (39 loc) · 1.05 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
FROM python:3.6.8-slim-stretch
WORKDIR /app
ENV LD_LIBRARY_PATH /usr/local/lib
RUN apt-get update \
&& apt-get upgrade -y \
&& apt-get install -y cmake git libgtk2.0-dev libblas-dev liblapack-dev \
&& rm -rf /var/lib/apt/lists/*
# install ngt
RUN git clone https://github.com/yahoojapan/NGT.git \
&& cd NGT \
&& git checkout v1.7.6 \
&& mkdir build && cd build \
&& cmake .. \
&& make \
&& make install \
&& ldconfig \
&& cd ../python \
&& pip install pybind11 \
&& python setup.py sdist \
&& pip install dist/ngt-1.4.0.tar.gz
# install hnsw
RUN git clone https://github.com/nmslib/hnsw.git \
&& cd hnsw/python_bindings \
&& pip install numpy pybind11 \
&& python setup.py install
# install faiss
RUN git clone https://github.com/facebookresearch/faiss.git \
&& cd faiss \
&& git checkout v1.4.0 \
&& ./configure \
&& make \
&& make install \
&& make py \
&& cd python \
&& python setup.py install
ARG VERSION
COPY dist/imgdupes-${VERSION}.tar.gz .
RUN pip install imgdupes-${VERSION}.tar.gz
ENTRYPOINT ["imgdupes"]