From 4e2c5aa49383281c0963ae11b2f4bb07c2fd0270 Mon Sep 17 00:00:00 2001 From: yihong0618 Date: Wed, 9 Aug 2023 20:24:37 +0800 Subject: [PATCH 1/4] feat: docker build actions --- .github/workflows/python-publish.yml | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index 3183e87e7..b47d6e275 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -17,9 +17,7 @@ permissions: jobs: deploy: - runs-on: ubuntu-latest - steps: - uses: actions/checkout@v3 - name: Set up Python @@ -37,3 +35,26 @@ jobs: with: user: __token__ password: ${{ secrets.PYPI_API_TOKEN }} + build-image: + runs-on: ubuntu-latest + needs: release-pypi + # run unless event type is pull_request + if: github.event_name != 'pull_request' + steps: + - uses: actions/checkout@v3 + - name: Set up QEMU + uses: docker/setup-qemu-action@v2 + - name: Set up Docker Buildx + uses: docker/setup-buildx-action@v2 + - name: Login to Docker Hub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + - name: Build and push + uses: docker/build-push-action@v4 + with: + context: . + platforms: linux/amd64,linux/arm64 + push: true + tags: eosphorosai/dbgpt:${{ github.ref_name }} From d1460e814b602fe772c78a148da7316fd79eef1d Mon Sep 17 00:00:00 2001 From: yihong0618 Date: Wed, 9 Aug 2023 20:26:30 +0800 Subject: [PATCH 2/4] fix: can trigger by dispatch --- .github/workflows/python-publish.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index b47d6e275..8112dbad2 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -11,6 +11,7 @@ name: Upload Python Package on: release: types: [published] + workflow_dispatch: permissions: contents: read From 90a87bc6177cdf08ebd38db1e76095d6cd269520 Mon Sep 17 00:00:00 2001 From: yihong0618 Date: Wed, 9 Aug 2023 20:27:19 +0800 Subject: [PATCH 3/4] fix: typo --- .github/workflows/python-publish.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index 8112dbad2..304749dfb 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -38,7 +38,7 @@ jobs: password: ${{ secrets.PYPI_API_TOKEN }} build-image: runs-on: ubuntu-latest - needs: release-pypi + needs: deploy # run unless event type is pull_request if: github.event_name != 'pull_request' steps: From e2eada3bab43d90d3de49a556a853ef6f8056a62 Mon Sep 17 00:00:00 2001 From: yihong0618 Date: Wed, 9 Aug 2023 21:00:35 +0800 Subject: [PATCH 4/4] fix: no MANIFEST.in --- MANIFEST.in | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 MANIFEST.in diff --git a/MANIFEST.in b/MANIFEST.in new file mode 100644 index 000000000..bb910ebb6 --- /dev/null +++ b/MANIFEST.in @@ -0,0 +1,3 @@ +include README.md +include LICENSE +include requirements.txt