Skip to content

armgit / dbx

Public Imported from GitHub
0

25 MB lightweight cross-platform database client for 100+ databases, including MySQL, PostgreSQL, SQLite, Redis, MongoDB, DuckDB, SQL Server, and Dameng. Built-in AI, MCP Server, CLI, desktop and Docker. | 轻量级跨平台数据库管理工具,支持 MySQL、PostgreSQL、SQLite、Redis、MongoDB、达梦等 100+ 数据库,提供桌面端、Docker、CLI、内置 AI 助手和 MCP。

fix(ci): split docker registry digests

t8y2827459c6ee1b
diff --git a/.github/workflows/docker-dev.yml b/.github/workflows/docker-dev.yml
index e453067897..2aa995816f 100644
--- a/.github/workflows/docker-dev.yml
+++ b/.github/workflows/docker-dev.yml
@@ -36,30 +36,48 @@ jobs:
username: cnb
password: ${{ secrets.CNB_TOKEN }}
- - name: Build and push by digest
- id: build
+ - name: Build and push Docker Hub by digest
+ id: build-dockerhub
uses: docker/build-push-action@v6
with:
context: .
file: deploy/Dockerfile
platforms: ${{ matrix.platform }}
- outputs: |
- type=image,name=${{ secrets.DOCKERHUB_USERNAME }}/dbx,push-by-digest=true,name-canonical=true,push=true
- type=image,name=${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }},push-by-digest=true,name-canonical=true,push=true
+ outputs: type=image,name=${{ secrets.DOCKERHUB_USERNAME }}/dbx,push-by-digest=true,name-canonical=true,push=true
cache-from: type=gha,scope=${{ matrix.platform }}-dev
cache-to: type=gha,scope=${{ matrix.platform }}-dev,mode=max
- - name: Export digest
+ - name: Build and push CNB by digest
+ id: build-cnb
+ uses: docker/build-push-action@v6
+ with:
+ context: .
+ file: deploy/Dockerfile
+ platforms: ${{ matrix.platform }}
+ outputs: type=image,name=${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }},push-by-digest=true,name-canonical=true,push=true
+ cache-from: type=gha,scope=${{ matrix.platform }}-dev
+
+ - name: Export digests
run: |
- mkdir -p /tmp/digests
- digest="${{ steps.build.outputs.digest }}"
- touch "/tmp/digests/${digest#sha256:}"
+ mkdir -p /tmp/digests/dockerhub /tmp/digests/cnb
+ dockerhub_digest="${{ steps.build-dockerhub.outputs.digest }}"
+ cnb_digest="${{ steps.build-cnb.outputs.digest }}"
+ touch "/tmp/digests/dockerhub/${dockerhub_digest#sha256:}"
+ touch "/tmp/digests/cnb/${cnb_digest#sha256:}"
+
+ - name: Upload Docker Hub digest
+ uses: actions/upload-artifact@v7
+ with:
+ name: dockerhub-digests-${{ matrix.platform == 'linux/amd64' && 'amd64' || 'arm64' }}
+ path: /tmp/digests/dockerhub/*
+ if-no-files-found: error
+ retention-days: 1
- - name: Upload digest
+ - name: Upload CNB digest
uses: actions/upload-artifact@v7
with:
- name: digests-${{ matrix.platform == 'linux/amd64' && 'amd64' || 'arm64' }}
- path: /tmp/digests/*
+ name: cnb-digests-${{ matrix.platform == 'linux/amd64' && 'amd64' || 'arm64' }}
+ path: /tmp/digests/cnb/*
if-no-files-found: error
retention-days: 1
@@ -67,11 +85,18 @@ jobs:
needs: docker
runs-on: ubuntu-latest
steps:
- - name: Download digests
+ - name: Download Docker Hub digests
+ uses: actions/download-artifact@v8
+ with:
+ path: /tmp/digests/dockerhub
+ pattern: dockerhub-digests-*
+ merge-multiple: true
+
+ - name: Download CNB digests
uses: actions/download-artifact@v8
with:
- path: /tmp/digests
- pattern: digests-*
+ path: /tmp/digests/cnb
+ pattern: cnb-digests-*
merge-multiple: true
- name: Set up Docker Buildx
@@ -91,12 +116,11 @@ jobs:
password: ${{ secrets.CNB_TOKEN }}
- name: Create manifest list and push
- working-directory: /tmp/digests
run: |
docker buildx imagetools create \
-t ${{ secrets.DOCKERHUB_USERNAME }}/dbx:dev \
- $(printf '${{ secrets.DOCKERHUB_USERNAME }}/dbx@sha256:%s ' *)
+ $(cd /tmp/digests/dockerhub && printf '${{ secrets.DOCKERHUB_USERNAME }}/dbx@sha256:%s ' *)
docker buildx imagetools create \
-t ${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }}:dev \
- $(printf '${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }}@sha256:%s ' *)
+ $(cd /tmp/digests/cnb && printf '${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }}@sha256:%s ' *)
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 78defa27aa..2e84dab268 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -370,30 +370,48 @@ jobs:
username: cnb
password: ${{ secrets.CNB_TOKEN }}
- - name: Build and push by digest
- id: build
+ - name: Build and push Docker Hub by digest
+ id: build-dockerhub
uses: docker/build-push-action@v6
with:
context: .
file: deploy/Dockerfile
platforms: ${{ matrix.platform }}
- outputs: |
- type=image,name=${{ secrets.DOCKERHUB_USERNAME }}/dbx,push-by-digest=true,name-canonical=true,push=true
- type=image,name=${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }},push-by-digest=true,name-canonical=true,push=true
+ outputs: type=image,name=${{ secrets.DOCKERHUB_USERNAME }}/dbx,push-by-digest=true,name-canonical=true,push=true
cache-from: type=gha,scope=${{ matrix.platform }}
cache-to: type=gha,scope=${{ matrix.platform }},mode=max
- - name: Export digest
+ - name: Build and push CNB by digest
+ id: build-cnb
+ uses: docker/build-push-action@v6
+ with:
+ context: .
+ file: deploy/Dockerfile
+ platforms: ${{ matrix.platform }}
+ outputs: type=image,name=${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }},push-by-digest=true,name-canonical=true,push=true
+ cache-from: type=gha,scope=${{ matrix.platform }}
+
+ - name: Export digests
run: |
- mkdir -p /tmp/digests
- digest="${{ steps.build.outputs.digest }}"
- touch "/tmp/digests/${digest#sha256:}"
+ mkdir -p /tmp/digests/dockerhub /tmp/digests/cnb
+ dockerhub_digest="${{ steps.build-dockerhub.outputs.digest }}"
+ cnb_digest="${{ steps.build-cnb.outputs.digest }}"
+ touch "/tmp/digests/dockerhub/${dockerhub_digest#sha256:}"
+ touch "/tmp/digests/cnb/${cnb_digest#sha256:}"
+
+ - name: Upload Docker Hub digest
+ uses: actions/upload-artifact@v7
+ with:
+ name: dockerhub-digests-${{ matrix.platform == 'linux/amd64' && 'amd64' || 'arm64' }}
+ path: /tmp/digests/dockerhub/*
+ if-no-files-found: error
+ retention-days: 1
- - name: Upload digest
+ - name: Upload CNB digest
uses: actions/upload-artifact@v7
with:
- name: digests-${{ matrix.platform == 'linux/amd64' && 'amd64' || 'arm64' }}
- path: /tmp/digests/*
+ name: cnb-digests-${{ matrix.platform == 'linux/amd64' && 'amd64' || 'arm64' }}
+ path: /tmp/digests/cnb/*
if-no-files-found: error
retention-days: 1
@@ -401,11 +419,18 @@ jobs:
needs: docker
runs-on: ubuntu-latest
steps:
- - name: Download digests
+ - name: Download Docker Hub digests
+ uses: actions/download-artifact@v8
+ with:
+ path: /tmp/digests/dockerhub
+ pattern: dockerhub-digests-*
+ merge-multiple: true
+
+ - name: Download CNB digests
uses: actions/download-artifact@v8
with:
- path: /tmp/digests
- pattern: digests-*
+ path: /tmp/digests/cnb
+ pattern: cnb-digests-*
merge-multiple: true
- name: Set up Docker Buildx
@@ -429,14 +454,13 @@ jobs:
run: echo "version=${GITHUB_REF_NAME#v}" >> "$GITHUB_OUTPUT"
- name: Create manifest list and push
- working-directory: /tmp/digests
run: |
docker buildx imagetools create \
-t ${{ secrets.DOCKERHUB_USERNAME }}/dbx:${{ steps.version.outputs.version }} \
-t ${{ secrets.DOCKERHUB_USERNAME }}/dbx:latest \
- $(printf '${{ secrets.DOCKERHUB_USERNAME }}/dbx@sha256:%s ' *)
+ $(cd /tmp/digests/dockerhub && printf '${{ secrets.DOCKERHUB_USERNAME }}/dbx@sha256:%s ' *)
docker buildx imagetools create \
-t ${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }}:${{ steps.version.outputs.version }} \
-t ${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }}:latest \
- $(printf '${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }}@sha256:%s ' *)
+ $(cd /tmp/digests/cnb && printf '${{ env.CNB_REGISTRY }}/${{ env.CNB_REPOSITORY }}@sha256:%s ' *)