Skip to content

Commit

Permalink
[feature/BLAZ-177] to dev (#378)
Browse files Browse the repository at this point in the history
* [BLAZ-177] Changes in setup.py and Dockerfile.application to solve security issues

* [BLAZ-177] Numpy transitive dependency limited to 1.x versions

* [BLAZ-177] Minor fix in setup.py

* [BLAZ-177] Changed graphviz runtime lib to graphviz-dev
  • Loading branch information
dantolin-iriusrisk authored Jul 10, 2024
1 parent 09c7ee0 commit f4a071b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
9 changes: 3 additions & 6 deletions deployment/Dockerfile.application
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ RUN apk --no-cache add lapack libstdc++ libmagic geos-dev && \

COPY . .

RUN pip install --upgrade pip

RUN pip install .


Expand All @@ -21,12 +23,7 @@ FROM python:3.8-alpine
WORKDIR /app

RUN apk update && \
apk add libmagic && \
apk add re2 && \
apk add graphviz && \
apk add lapack && \
apk add cblas && \
apk add geos
apk add libmagic re2 lapack cblas geos graphviz-dev

COPY --from=startleft-base /usr/local/lib/python3.8/site-packages /usr/local/lib/python3.8/site-packages

Expand Down
7 changes: 5 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
'deepmerge==1.1.0',
'jmespath==1.0.1',
'python-hcl2==4.3.2',
'requests==2.31.0',
'requests==2.32.3',
'fastapi==0.109.2',
'python-multipart==0.0.7',
'click==8.1.7',
Expand All @@ -37,7 +37,10 @@
'xmlschema==2.5.0',
'word2number==1.1',
# Do not upgrade pygraphviz unless security issues because it is heavily dependent on the underlying OS
'pygraphviz==1.10'
'pygraphviz==1.10',
# Numpy is a transitive dependency of fastapi, requests and python-multipart
# They require different v1 versions, while v2 versions lead to import errors
'numpy<2.0'
],
use_scm_version={
'write_to': 'startleft/version.py',
Expand Down

0 comments on commit f4a071b

Please sign in to comment.