mirror of
https://github.com/scito/extract_otp_secret_keys.git
synced 2026-01-06 13:25:41 +01:00
rename ARG run_tests to RUN_TESTS
This commit is contained in:
parent
aa0de699fe
commit
1dee86668a
4 changed files with 7 additions and 7 deletions
4
.github/workflows/ci_docker.yml
vendored
4
.github/workflows/ci_docker.yml
vendored
|
|
@ -58,6 +58,8 @@ jobs:
|
|||
# build on feature branches, push only on master branch
|
||||
# TODO push: ${{ github.ref == 'refs/heads/master' }}
|
||||
push: true
|
||||
build-args: |
|
||||
RUN_TESTS=false
|
||||
|
||||
- name: "qr_reader: Build image and push to Docker Hub and GitHub Container Registry"
|
||||
uses: docker/build-push-action@v2
|
||||
|
|
@ -72,8 +74,6 @@ jobs:
|
|||
# build on feature branches, push only on master branch
|
||||
# TODO push: ${{ github.ref == 'refs/heads/master' }}
|
||||
push: true
|
||||
build-args: |
|
||||
run_tests=false
|
||||
|
||||
- name: Image digest
|
||||
run: echo ${{ steps.docker_build.outputs.digest }}
|
||||
|
|
|
|||
|
|
@ -4,11 +4,11 @@ WORKDIR /extract
|
|||
|
||||
COPY . .
|
||||
|
||||
ARG run_tests=true
|
||||
ARG RUN_TESTS=true
|
||||
|
||||
RUN apt-get update && apt-get install -y libzbar0 python3-opencv nano \
|
||||
&& pip install -r requirements.txt \
|
||||
&& if [[ "$run_tests" == "true" ]]; then /extract/run_pytest.sh; else echo "Not running tests..."; fi
|
||||
&& if [[ "$RUN_TESTS" == "true" ]]; then /extract/run_pytest.sh; else echo "Not running tests..."; fi
|
||||
|
||||
WORKDIR /files
|
||||
|
||||
|
|
|
|||
|
|
@ -4,14 +4,14 @@ WORKDIR /extract
|
|||
|
||||
COPY . .
|
||||
|
||||
ARG run_tests=true
|
||||
ARG RUN_TESTS=true
|
||||
|
||||
RUN apk add --no-cache nano \
|
||||
&& echo "Arch: $(apk --print-arch)" \
|
||||
&& if [[ "$(apk --print-arch)" == "aarch64" ]]; then apk add --no-cache --virtual .build-deps gcc libc-dev python3-dev py3-setuptools zlib-dev jpeg-dev; fi \
|
||||
&& pip install protobuf qrcode Pillow \
|
||||
&& if [[ "$(apk --print-arch)" == "aarch64" ]]; then apk del .build-deps; fi \
|
||||
&& if [[ "$run_tests" == "true" ]]; then /extract/run_pytest.sh test_extract_otp_secret_keys_pytest.py -k "not qreader" --relaxed; else echo "Not running tests..."; fi
|
||||
&& if [[ "$RUN_TESTS" == "true" ]]; then /extract/run_pytest.sh test_extract_otp_secret_keys_pytest.py -k "not qreader" --relaxed; else echo "Not running tests..."; fi
|
||||
|
||||
WORKDIR /files
|
||||
|
||||
|
|
|
|||
|
|
@ -335,7 +335,7 @@ docker run --entrypoint /extract/run_pytest.sh --rm -v "$(pwd)":/files:ro extrac
|
|||
|
||||
docker login -uscit0
|
||||
docker build . -t extract_otp_secret_keys_no_qr_reader -f Dockerfile_no_qr_reader --pull
|
||||
docker build . -t extract_otp_secret_keys_no_qr_reader -f Dockerfile_no_qr_reader --pull --build-arg run_tests=false
|
||||
docker build . -t extract_otp_secret_keys_no_qr_reader -f Dockerfile_no_qr_reader --pull --build-arg RUN_TESTS=false
|
||||
docker run --entrypoint /extract/run_pytest.sh --rm -v "$(pwd)":/files:ro extract_otp_secret_keys_no_qr_reader
|
||||
docker run --entrypoint /extract/run_pytest.sh --rm -v "$(pwd)":/files:ro extract_otp_secret_keys_no_qr_reader test_extract_otp_secret_keys_pytest.py -k "not qreader"
|
||||
docker run --rm -v "$(pwd)":/files:ro extract_otp_secret_keys_no_qr_reader example_export.txt
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue