Skip to content
This repository has been archived by the owner on Jun 11, 2023. It is now read-only.

Commit

Permalink
Pass in Python package version
Browse files Browse the repository at this point in the history
  • Loading branch information
Bruno Grande committed Aug 20, 2022
1 parent 7f6f6fd commit d5c0a30
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@ jobs:
with:
platforms: linux/amd64,linux/arm64
push: true
build-args:
- PKG_VERSION=${{ env.DOCKER_TAG }}
tags: |
${{ env.DOCKER_ORG }}/${{ env.DOCKER_REPO }}:latest
${{ env.DOCKER_ORG }}/${{ env.DOCKER_REPO }}:${{ env.DOCKER_TAG }}
7 changes: 2 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,14 @@ FROM python:3.10.6

WORKDIR /usr/src/app

ARG PSEUDO_VERSION=1
ARG PKG_VERSION=1

RUN pip install --no-cache-dir pipenv

COPY setup.* Pipfile* ./
COPY src ./src/

RUN SETUPTOOLS_SCM_PRETEND_VERSION_FOR_SAGETASKS=${PSEUDO_VERSION} \
pipenv install --system

RUN --mount=source=.git,target=.git,type=bind \
RUN SETUPTOOLS_SCM_PRETEND_VERSION_FOR_SAGETASKS=${PKG_VERSION} \
pipenv install --system

CMD [ "python", "-c", "import sagetasks" ]

0 comments on commit d5c0a30

Please sign in to comment.