update docs

This commit is contained in:
scito
2023-01-01 10:03:44 +01:00
parent 13fcdcd022
commit 19c8e9df23
5 changed files with 52 additions and 20 deletions

View File

@@ -1,5 +1,7 @@
FROM python:3.11-alpine
# https://docs.docker.com/engine/reference/builder/
# For debugging
# docker run --rm -v "$(pwd)":/files:ro extract_otp_secrets_only_txt
# docker build . -t extract_otp_secrets_only_txt -f Dockerfile_only_txt --pull --build-arg RUN_TESTS=false
@@ -12,10 +14,23 @@ COPY . .
ARG RUN_TESTS=true
RUN apk add --no-cache zlib jpeg \
RUN apk add --no-cache \
zlib \
jpeg \
&& 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 --no-cache-dir protobuf qrcode Pillow colorama \
&& 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 --no-cache-dir \
protobuf \
qrcode \
Pillow \
colorama \
&& if [[ "$(apk --print-arch)" == "aarch64" ]]; then apk del .build-deps; fi \
&& if [[ "$RUN_TESTS" == "true" ]]; then /extract/run_pytest.sh tests/extract_otp_secrets_test.py -k "not qreader" --relaxed; else echo "Not running tests..."; fi