build: look for repository first
Some checks failed
Build and Publish Docker Images / build-and-push (backend) (push) Failing after 6m53s
Build and Publish Docker Images / build-and-push (frontend) (push) Failing after 6m35s

This commit is contained in:
2025-08-29 08:28:57 +02:00
parent ff867fd219
commit e561dd5b74

View File

@@ -32,6 +32,14 @@ jobs:
username: ${{ secrets.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_PASSWORD }}
- name: Ensure repository exists
run: |
curl -f -X POST \
-H "Authorization: token ${{ secrets.REGISTRY_PASSWORD }}" \
-H "Content-Type: application/json" \
-d '{"name":"zebra-power","private":false,"description":"Zebra Power Docker Images"}' \
${{ env.REGISTRY }}/api/v1/user/repos || echo "Repository may already exist"
- name: Extract metadata
id: meta
uses: docker/metadata-action@v5