Skip to content

Commit

Permalink
Add release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
soapy1 committed Jan 3, 2025
1 parent 7a34d9e commit 0b306e8
Showing 1 changed file with 42 additions and 0 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -145,3 +145,45 @@ jobs:
npm publish --verbose --access public ${{ env.PACKAGE_FILE }}
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

build_and_push_docker_image:
name: "Build Docker Images 🛠"
runs-on: ubuntu-latest
needs: release-to-npmjs:
permissions:
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
steps:
- name: "Checkout Repository 🛎"
uses: actions/checkout@v4

- name: "Set up Docker Buildx 🏗"
uses: docker/setup-buildx-action@v3

- name: "Login to Docker Hub 🐳"
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: "Add Docker metadata 📝"
id: meta
uses: docker/metadata-action@v5
with:
images: |
quansight/conda-store-ui
tags: |
type=ref,event=tag
type=ref,event=branch
type=sha
- name: "Publish Docker image 🚀"
uses: docker/build-push-action@v5
with:
context: .
target: "prod"
tags: |
${{ steps.meta.outputs.tags }}
push: true
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max

0 comments on commit 0b306e8

Please sign in to comment.