Merge branch 'fix-security-scanner' into 'main'
Use virtualenv for security-scanner See merge request fablab/labsync!76
This commit is contained in:
commit
61a68b6b4c
2 changed files with 6 additions and 3 deletions
|
|
@ -57,7 +57,7 @@ security_scanner:
|
||||||
script:
|
script:
|
||||||
- set -x
|
- set -x
|
||||||
- export GITLAB_URL="$(echo "$CI_PROJECT_URL" | grep -Eo '^https?://[^/]*')"
|
- export GITLAB_URL="$(echo "$CI_PROJECT_URL" | grep -Eo '^https?://[^/]*')"
|
||||||
- python3 -m security_scanner $target
|
- /code/venv/bin/python -m security_scanner $target
|
||||||
only:
|
only:
|
||||||
refs:
|
refs:
|
||||||
- schedules
|
- schedules
|
||||||
|
|
|
||||||
|
|
@ -7,14 +7,17 @@ RUN apt-get update \
|
||||||
python3 \
|
python3 \
|
||||||
python3-apt \
|
python3-apt \
|
||||||
python3-pip \
|
python3-pip \
|
||||||
|
python3-venv \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
COPY setup.py /code/setup.py
|
COPY setup.py /code/setup.py
|
||||||
|
|
||||||
WORKDIR /code
|
WORKDIR /code
|
||||||
|
|
||||||
RUN pip3 install -e .
|
RUN python3 -m venv --system-site-packages venv
|
||||||
|
|
||||||
|
RUN venv/bin/pip install -e .
|
||||||
|
|
||||||
ADD . /code
|
ADD . /code
|
||||||
|
|
||||||
RUN python3 setup.py install
|
RUN venv/bin/python setup.py install
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue