From fcc6d1ee0e54a878d1418ff14c51662e68b7d67e Mon Sep 17 00:00:00 2001 From: Marcos Antonio Lopes Date: Wed, 29 Oct 2025 11:26:20 +1000 Subject: [PATCH 1/4] fix build arg interpolation --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index d08a04c1..9e90f338 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,6 +5,6 @@ ARG VERSION RUN apk add sed COPY entrypoint.sh /entrypoint.sh -RUN pip install kubernetes-validate==$(VERSION) +RUN pip install kubernetes-validate==${VERSION} ENTRYPOINT ["/entrypoint.sh"] From b7a8782dddb766711bf3dc810bd81e1f28270fe2 Mon Sep 17 00:00:00 2001 From: Marcos Antonio Lopes Date: Wed, 29 Oct 2025 12:18:59 +1000 Subject: [PATCH 2/4] Publish to PypI before trying to build the docker image --- .github/workflows/publish.yml | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index d8fe7e95..c53f21cc 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -7,8 +7,26 @@ on: - 'gh-action-test-*' jobs: + pypi: + name: Upload release to PyPI + runs-on: ubuntu-latest + environment: + name: release + url: https://pypi.org/p/kubernetes-validate + permissions: + id-token: write # IMPORTANT: this permission is mandatory for trusted publishing + steps: + - name: Checkout + uses: actions/checkout@master + - name: Build pypi package + run: | + python -m pip install build twine && python -m build + - name: Publish package distributions to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + docker: runs-on: ubuntu-latest + needs: pypi permissions: packages: write contents: read @@ -28,19 +46,3 @@ jobs: tags: ghcr.io/${{github.repository}}:${{github.ref_name}} labels: org.opencontainers.image.source=https://github.com/${{github.repository}} - pypi: - name: Upload release to PyPI - runs-on: ubuntu-latest - environment: - name: release - url: https://pypi.org/p/kubernetes-validate - permissions: - id-token: write # IMPORTANT: this permission is mandatory for trusted publishing - steps: - - name: Checkout - uses: actions/checkout@master - - name: Build pypi package - run: | - python -m pip install build twine && python -m build - - name: Publish package distributions to PyPI - uses: pypa/gh-action-pypi-publish@release/v1 From 952cabb7b0a557370e823e2f36aedb07cb9852f4 Mon Sep 17 00:00:00 2001 From: Marcos Antonio Lopes Date: Wed, 29 Oct 2025 12:27:01 +1000 Subject: [PATCH 3/4] update __version__ to 1.34.1 --- src/kubernetes_validate/version.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/kubernetes_validate/version.py b/src/kubernetes_validate/version.py index 01eb91ea..4f36c23b 100644 --- a/src/kubernetes_validate/version.py +++ b/src/kubernetes_validate/version.py @@ -1 +1 @@ -__version__ = '1.34.0' +__version__ = '1.34.1' From 32e4e6ae4343fb9363040977930c160dfa30a0b0 Mon Sep 17 00:00:00 2001 From: Marcos Antonio Lopes Date: Wed, 29 Oct 2025 12:31:57 +1000 Subject: [PATCH 4/4] checkout code for 2nd docker step --- .github/workflows/publish.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index c53f21cc..90029fe7 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -31,6 +31,8 @@ jobs: packages: write contents: read steps: + - name: Checkout + uses: actions/checkout@master - name: Log in to registry run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u $ --password-stdin - name: get version