diff --git a/.gitea/workflows/build-push.yaml b/.gitea/workflows/build-push.yaml index 3698fdb..ad89e28 100644 --- a/.gitea/workflows/build-push.yaml +++ b/.gitea/workflows/build-push.yaml @@ -26,17 +26,30 @@ jobs: apt-get update apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin + # Add step to configure Docker for possible insecure registry + - name: Configure Docker for Harbor + run: | + mkdir -p /etc/docker + echo '{"insecure-registries": ["harbor.galpodlipnik.com"]}' > /etc/docker/daemon.json + # Restart Docker to apply changes + service docker restart || true + # Add some diagnostic info + echo "Testing connectivity to Harbor..." + curl -v --connect-timeout 10 https://harbor.galpodlipnik.com || echo "Connection failed but continuing" + - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 with: install: true - - name: Login to Harbor + - name: Login to Harbor with retries uses: docker/login-action@v3 with: registry: harbor.galpodlipnik.com username: ${{ secrets.HARBOR_USERNAME }} password: ${{ secrets.HARBOR_PASSWORD }} + # Add a longer timeout for login attempts + timeout: 180 - name: Build and push uses: docker/build-push-action@v5