fix: use build-push-action with oci-mediatypes=true for Zot compatibility
Switch from docker buildx CLI to docker/build-push-action@v5 with oci-mediatypes=true to push OCI-format manifests that Zot accepts. Also type-check all three Python files in CI.
This commit is contained in:
+11
-14
@@ -24,7 +24,7 @@ jobs:
|
|||||||
run: ruff check .
|
run: ruff check .
|
||||||
|
|
||||||
- name: Type check
|
- name: Type check
|
||||||
run: mypy check_versions.py --ignore-missing-imports
|
run: mypy check_versions.py request_upgrades.py web.py
|
||||||
|
|
||||||
build-push:
|
build-push:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@@ -37,19 +37,16 @@ jobs:
|
|||||||
uses: docker/setup-buildx-action@v3
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
- name: Build and push image
|
- name: Build and push image
|
||||||
run: |
|
uses: docker/build-push-action@v5
|
||||||
if [ -n "${{ secrets.REGISTRY_USERNAME }}" ]; then
|
with:
|
||||||
echo "${{ secrets.REGISTRY_PASSWORD }}" | \
|
context: .
|
||||||
docker login ${{ secrets.REGISTRY_URL }} -u ${{ secrets.REGISTRY_USERNAME }} --password-stdin
|
platforms: linux/amd64
|
||||||
fi
|
provenance: false
|
||||||
docker buildx build \
|
sbom: false
|
||||||
--platform linux/amd64 \
|
outputs: type=image,push=true,oci-mediatypes=true
|
||||||
--provenance=false \
|
tags: |
|
||||||
--sbom=false \
|
${{ secrets.REGISTRY_URL }}/k8s-version-tracker:${{ github.sha }}
|
||||||
--tag ${{ secrets.REGISTRY_URL }}/k8s-version-tracker:${{ github.sha }} \
|
${{ secrets.REGISTRY_URL }}/k8s-version-tracker:latest
|
||||||
--tag ${{ secrets.REGISTRY_URL }}/k8s-version-tracker:latest \
|
|
||||||
--push \
|
|
||||||
.
|
|
||||||
|
|
||||||
- name: Notify Mattermost
|
- name: Notify Mattermost
|
||||||
if: always()
|
if: always()
|
||||||
|
|||||||
Reference in New Issue
Block a user