fix: use regctl for OCI-format push to Zot registry
Zot registry only accepts OCI Image Manifest format, not Docker v2. Switched from docker push to regctl image import/copy. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -15,18 +15,23 @@ jobs:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Build and push Docker image
|
||||
- name: Build and push Docker image (OCI format for Zot registry)
|
||||
run: |
|
||||
docker login registry.storedbox.net \
|
||||
-u ${{ secrets.DOCKER_USER }} \
|
||||
-p ${{ secrets.DOCKER_PASSWORD }}
|
||||
# Download regctl for OCI-compatible push (Zot requires OCI format)
|
||||
curl -sL https://github.com/regclient/regclient/releases/latest/download/regctl-linux-amd64 \
|
||||
-o /usr/local/bin/regctl && chmod +x /usr/local/bin/regctl
|
||||
|
||||
docker build -t registry.storedbox.net/ollama-mcp:${{ github.sha }} .
|
||||
docker tag registry.storedbox.net/ollama-mcp:${{ github.sha }} \
|
||||
registry.storedbox.net/ollama-mcp:latest
|
||||
|
||||
docker push registry.storedbox.net/ollama-mcp:${{ github.sha }}
|
||||
docker push registry.storedbox.net/ollama-mcp:latest
|
||||
docker save registry.storedbox.net/ollama-mcp:${{ github.sha }} \
|
||||
-o /tmp/ollama-mcp.tar
|
||||
regctl image import registry.storedbox.net/ollama-mcp:${{ github.sha }} \
|
||||
/tmp/ollama-mcp.tar
|
||||
regctl image copy \
|
||||
registry.storedbox.net/ollama-mcp:${{ github.sha }} \
|
||||
registry.storedbox.net/ollama-mcp:latest
|
||||
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
Reference in New Issue
Block a user