diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index c83dd52..8eb6a91 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -23,6 +23,16 @@ lint-dockerfiles: rules: - when: always +test-pypi: + stage: test + script: + - docker pull $IMAGE_BASE/pypi || true + - docker build --cache-from $IMAGE_BASE/pypi --tag $IMAGE_BASE/pypi:$CI_COMMIT_SHA --tag $IMAGE_BASE/pypi:latest -f Dockerfile.pypi . + rules: + - if: $CI_COMMIT_BRANCH != "master" + changes: + - Dockerfile.pypi + test-debian: stage: test script: @@ -83,6 +93,18 @@ test-documentation: changes: - Dockerfile.documentation +build-pypi: + stage: build + script: + - docker pull $IMAGE_BASE/pypi || true + - docker build --cache-from $IMAGE_BASE/pypi --tag $IMAGE_BASE/pypi:$CI_COMMIT_SHA --tag $IMAGE_BASE/pypi:latest -f Dockerfile.pypi . + - docker push $IMAGE_BASE/pypi:$CI_COMMIT_SHA + - docker push $IMAGE_BASE/pypi:latest + rules: + - if: $CI_COMMIT_BRANCH == "master" + changes: + - Dockerfile.pypi + build-debian: stage: build script: diff --git a/Dockerfile.pypi b/Dockerfile.pypi new file mode 100644 index 0000000..0bc16a9 --- /dev/null +++ b/Dockerfile.pypi @@ -0,0 +1,5 @@ +FROM python:3.12 + +RUN apt-get update && DEBIAN_FRONTEND=noninteractive \ + apt-get install -y python3-dev libdbus-1-dev libegl1 libxkbcommon0 libnss3 libxcomposite1 libxdamage1 libxtst6 \ + libxi6 libasound2 libpulse0 xvfb