Skip to content

Fix file upload to read contents instead of passing raw fileList obje… #44

Fix file upload to read contents instead of passing raw fileList obje…

Fix file upload to read contents instead of passing raw fileList obje… #44

name: Build and publish
on:
push:
branches:
- master
workflow_dispatch:
permissions:
contents: read # for checkout
jobs:
build-and-release:
runs-on: ubuntu-latest
permissions:
contents: write # to publish a GitHub release
issues: write # to comment on released issues
pull-requests: write # to comment on released pull requests
id-token: write # to enable use of OIDC for npm provenance
steps:
- name: Checkout
uses: actions/checkout@v4.1.6
with:
fetch-depth: 0 # Required for semantic-release
- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: 1.3.5
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '22.14.0'
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Build React app
run: bun run build
- name: Set IMAGE_TAG as env
run: |
IMAGE_TAG=$(git rev-parse --short=7 ${{ github.sha }})
echo "IMAGE_TAG=${IMAGE_TAG}" >> $GITHUB_ENV
- name: Login to Docker Hub
uses: docker/login-action@v3.3.0
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_PASSWORD }}
- name: Build and push Docker image
uses: docker/build-push-action@v6.9.0
with:
context: .
file: ./Dockerfile
push: true
tags: quicklookup/synmetrix-client-v2:${{ env.IMAGE_TAG }}