diff --git a/core-builder/.gitignore b/core-builder/.gitignore new file mode 100644 index 0000000000..f9bf21dcc4 --- /dev/null +++ b/core-builder/.gitignore @@ -0,0 +1 @@ +dev_requirements.txt diff --git a/core-builder/Dockerfile b/core-builder/Dockerfile index d444c10a51..d21cf3bd8b 100644 --- a/core-builder/Dockerfile +++ b/core-builder/Dockerfile @@ -85,7 +85,7 @@ RUN rm -rf /usr/local/bin/pip && \ RUN pip install --upgrade pip RUN pip install --upgrade setuptools -RUN pip install pyyaml +RUN pip install pyyaml RUN pip install grpcio RUN pip install grpcio-tools RUN apt-get remove -y --auto-remove && apt-get clean -y && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* @@ -120,14 +120,12 @@ RUN go get github.com/fullstorydev/grpcurl && \ go install github.com/fullstorydev/grpcurl/cmd/grpcurl ENV PATH="${PATH}:/root/go/bin" - + # Notebooks python requirements -RUN pip install alibi && \ - pip install matplotlib && \ - pip install keras +COPY dev_requirements.txt /tmp/requirements.txt +RUN pip install -r /tmp/requirements.txt WORKDIR /work # Define default command. CMD ["bash"] - diff --git a/core-builder/Makefile b/core-builder/Makefile index c11c873116..40ee711b98 100644 --- a/core-builder/Makefile +++ b/core-builder/Makefile @@ -1,8 +1,8 @@ DOCKER_IMAGE_NAME=seldonio/core-builder -DOCKER_IMAGE_VERSION=0.13 +DOCKER_IMAGE_VERSION=0.14 build_docker_image: + cp ../testing/scripts/dev_requirements.txt . docker build --force-rm=true -t $(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_VERSION) . push_to_registry: docker push $(DOCKER_IMAGE_NAME):$(DOCKER_IMAGE_VERSION) - diff --git a/testing/scripts/Makefile b/testing/scripts/Makefile index a47a34767b..f0205fc4c4 100644 --- a/testing/scripts/Makefile +++ b/testing/scripts/Makefile @@ -98,6 +98,7 @@ build_protos: install: pip install -r dev_requirements.txt + pip install -e ../../python .PHONY: test test: build_protos install diff --git a/testing/scripts/dev_requirements.txt b/testing/scripts/dev_requirements.txt index 03bf898a93..2d13b4ec7e 100644 --- a/testing/scripts/dev_requirements.txt +++ b/testing/scripts/dev_requirements.txt @@ -4,8 +4,12 @@ pytest-cov==2.8.1 flaky==3.6.1 tenacity==6.0.0 +# notebooks test deps +ipython==7.13.0 +nbconvert==5.6.1 +alibi==0.3.2 +matplotlib==3.1.3 +tensorflow==1.15.2 + # 2nd lvl dep on cov required to avoid sqllite dep coverage==4.5.4 - -# local seldon-core --e ../../python