Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
fphammerle committed Nov 5, 2023
1 parent c5cffda commit 81a8a42
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,19 @@ ARG SOURCE_DIR_PATH=/switchbot-mqtt
FROM $BASE_IMAGE as build

RUN apk add --no-cache \
cargo `# cryptography build` \
gcc \
git `# setuptools_scm` \
glib-dev \
jq `# edit Pipfile.lock` \
make \
musl-dev \
openssl-dev `# cryptography build` \
py3-certifi `# pipenv` \
py3-pip `# pipenv install` \
py3-virtualenv `# pipenv` \
python3-dev `# Python.h for cffi build` \
rust `# cryptography build` \
&& adduser -S build

USER build
Expand All @@ -33,9 +37,10 @@ ENV PIPENV_CACHE_DIR=/tmp/pipenv-cache \
# `sponge` is not pre-installed
RUN jq 'del(.default."switchbot-mqtt", .default."sanitized-package")' Pipfile.lock > Pipfile.lock~ \
&& mv Pipfile.lock~ Pipfile.lock \
&& pipenv install --deploy --verbose
&& pipenv install --deploy
COPY --chown=build:nobody . $SOURCE_DIR_PATH
RUN pipenv install --deploy --verbose \
RUN if ! git status; then export SETUPTOOLS_SCM_PRETEND_VERSION=0.0.0; fi \
&& pipenv install --deploy \
&& pipenv graph \
&& pipenv run pip freeze \
&& rm -rf .git/ $PIPENV_CACHE_DIR \
Expand Down

0 comments on commit 81a8a42

Please sign in to comment.