From a3b78f5ae2fba323bea774d7f1e872d88a654ced Mon Sep 17 00:00:00 2001 From: Mario Fink Date: Tue, 26 Jan 2021 16:34:01 +0100 Subject: [PATCH] update and fix Dockerfile --- Dockerfile | 7 ++++++- cython/py_tdm_reaper.pyx | 2 +- cython/requirements.txt | 1 - makefile | 2 +- python/usage.py | 2 +- 5 files changed, 9 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 9ee403b..735ef88 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,12 +4,17 @@ FROM debian:bullseye-20210111 USER root RUN apt-get update && apt-get install -y \ - build-essential git + build-essential git \ + python3 python3-pip RUN g++ -v COPY ./ /tdm_ripper/ +# install CLI tool RUN cd /tdm_ripper && ls -lh && make install && ls -lh /usr/local/bin/tdmreaper +# install Python module +RUN cd /tdm_ripper && ls -lh && make cython-requirements && make cython-install + CMD ["sleep","inifity"] diff --git a/cython/py_tdm_reaper.pyx b/cython/py_tdm_reaper.pyx index c66f081..f8df4c6 100644 --- a/cython/py_tdm_reaper.pyx +++ b/cython/py_tdm_reaper.pyx @@ -2,7 +2,7 @@ from tdm_reaper cimport tdm_reaper import json as jn -import numpy as np +# import numpy as np cdef class tdmreaper: diff --git a/cython/requirements.txt b/cython/requirements.txt index 5a7a437..b6fe7ec 100644 --- a/cython/requirements.txt +++ b/cython/requirements.txt @@ -1,2 +1 @@ Cython==0.29.21 -numpy==1.18.4 diff --git a/makefile b/makefile index 4ebe3e7..d5a26db 100644 --- a/makefile +++ b/makefile @@ -81,7 +81,7 @@ cython-build : cython/setup.py cython/tdm_reaper.pxd cython/py_tdm_reaper.pyx $( python3 $< build_ext --inplace cp -v tdm_reaper.cpython-*.so python/ -cython-install : cython/setup.py cython/tdm_reaper.pyx cython/tdm_reaper.pyx +cython-install : cython/setup.py cython/tdm_reaper.pxd cython/py_tdm_reaper.pyx $(HPP) lib/tdm_reaper.cpp python3 $< install clean-cython : diff --git a/python/usage.py b/python/usage.py index 0cf4ff7..5447ae0 100644 --- a/python/usage.py +++ b/python/usage.py @@ -1,6 +1,6 @@ import tdm_reaper -import numpy as np +# import numpy as np import json import re