From 66d7a4c8058eed250153874d2630b4a4ed363c05 Mon Sep 17 00:00:00 2001 From: Sercan Sahin Date: Sun, 13 Apr 2025 19:44:41 +0200 Subject: [PATCH 1/3] implement skeleton of DockerHub ci --- .github/workflows/release.yml | 41 +++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 991e8ad7b..11b8555bd 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -31,3 +31,44 @@ jobs: uses: pypa/gh-action-pypi-publish@release/v1 with: password: ${{ secrets.PYPI_ORG_TOKEN }} + + build-and-push: + # This job publishes the server docker image to DockerHub + runs-on: ubuntu-latest + defaults: + run: + working-directory: ./server + steps: + - name: Checkout Repository + uses: actions/checkout@v4 + + - name: Extract Docker image metadata + id: meta + uses: docker/metadata-action@v5 + with: + images: ${{ vars.DOCKERHUB_USERNAME }}/basyx-python-server + tags: | + type=semver,pattern={{version}} + type=raw,value=latest + labels: | + org.opencontainers.image.title=BaSyx Python Server + org.opencontainers.image.description=Eclipse BaSyx Python SDK - HTTP Server + org.opencontainers.image.source=https://github.com/eclipse-basyx/basyx-python-sdk/tree/main/server + org.opencontainers.image.licenses=MIT + + - name: Log in to DockerHub + uses: docker/login-action@v3 + with: + username: ${{ vars.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + + - name: Build and Push Docker Image + uses: docker/build-push-action@v6 + with: + context: .. + file: ./Dockerfile + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + + From fbbdd835c78e2d5f598f318aa128846bbab66027 Mon Sep 17 00:00:00 2001 From: s-heppner Date: Mon, 20 Apr 2026 14:28:34 +0200 Subject: [PATCH 2/3] Update Docker release configuration This updates the `publish-dockerhub` configuration to be more in line with the basyx-java-server. --- .github/workflows/release.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 11b8555bd..ffc58b287 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -5,7 +5,7 @@ on: types: [published] jobs: - publish: + publish-pypi: # This job publishes the package to PyPI runs-on: ubuntu-latest defaults: @@ -32,7 +32,7 @@ jobs: with: password: ${{ secrets.PYPI_ORG_TOKEN }} - build-and-push: + publish-dockerhub: # This job publishes the server docker image to DockerHub runs-on: ubuntu-latest defaults: @@ -46,7 +46,8 @@ jobs: id: meta uses: docker/metadata-action@v5 with: - images: ${{ vars.DOCKERHUB_USERNAME }}/basyx-python-server + images: eclipsebasyx/basyx-python-server + # This fetches the latest git tag and adds an additional "latest" to it, so e.g. `2.1.0,latest` tags: | type=semver,pattern={{version}} type=raw,value=latest @@ -56,19 +57,18 @@ jobs: org.opencontainers.image.source=https://github.com/eclipse-basyx/basyx-python-sdk/tree/main/server org.opencontainers.image.licenses=MIT - - name: Log in to DockerHub - uses: docker/login-action@v3 + - name: Log in to Docker Hub + uses: docker/login-action@v4 with: - username: ${{ vars.DOCKERHUB_USERNAME }} - password: ${{ secrets.DOCKERHUB_TOKEN }} + username: ${{ secrets.DOCKER_HUB_USER }} + password: ${{ secrets.DOCKER_HUB_TOKEN }} - name: Build and Push Docker Image uses: docker/build-push-action@v6 with: context: .. - file: ./Dockerfile + file: ./Dockerfile # Todo: Update paths push: true + platforms: linux/amd64,linux/arm64 # Todo: Check which platforms we should support tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} - - From 11427e4c0ac1f480049e14c8d460ab70abed87f3 Mon Sep 17 00:00:00 2001 From: s-heppner Date: Mon, 20 Apr 2026 15:32:50 +0200 Subject: [PATCH 3/3] Remove multiplatform support from DockerHub publishing for now --- .github/workflows/release.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 7c325d303..2f147c17a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -96,6 +96,5 @@ jobs: context: . file: ./server/Dockerfile # Todo: Update paths push: true - platforms: linux/amd64,linux/arm64 # Todo: Check which platforms we should support tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }}