Skip to content

Commit

Permalink
feat: docker actions and fix can not use python -m build bug (#422)
Browse files Browse the repository at this point in the history
- add docker actions (you need add the secret to the repo
- fix can not use `python -m build` for release -> (which actions
release use)
  • Loading branch information
Aries-ckt authored Aug 11, 2023
2 parents f007874 + e2eada3 commit 85344e8
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 2 deletions.
26 changes: 24 additions & 2 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,14 @@ name: Upload Python Package
on:
release:
types: [published]
workflow_dispatch:

permissions:
contents: read

jobs:
deploy:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Set up Python
Expand All @@ -37,3 +36,26 @@ jobs:
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
build-image:
runs-on: ubuntu-latest
needs: deploy
# 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 }}
3 changes: 3 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
include README.md
include LICENSE
include requirements.txt

0 comments on commit 85344e8

Please sign in to comment.