Compare commits

..

3 Commits

Author SHA1 Message Date
453aa0a4ec chore(release): 1.6.7 2026-03-04 16:36:57 +08:00
fe37cce13e Fix publish.yml 2026-03-04 16:08:59 +08:00
ee05d0c71f Build Github 2026-03-04 15:18:01 +08:00
4 changed files with 28 additions and 13 deletions

View File

@@ -1,17 +1,26 @@
name: Publish Docker to GHCR
on:
workflow_dispatch:
inputs:
environment:
description: "Target environment"
required: true
type: choice
options:
- production
- staging
tag:
description: "Image tag (e.g. v1.0.0)"
required: true
default: "latest"
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
jobs:
publish:
name: Build & Push to GHCR
name: Build & Push to GHCR (${{ github.event.inputs.environment }})
runs-on: ubuntu-latest
permissions:
contents: read
@@ -29,10 +38,6 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4
- name: Extract tag name
id: meta
run: echo "tag=${{ github.event.inputs.tag }}" >> $GITHUB_OUTPUT
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
@@ -46,6 +51,15 @@ jobs:
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Generate image metadata
id: meta
uses: docker/metadata-action@v5
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=raw,value=${{ github.event.inputs.environment }}-${{ github.event.inputs.tag }}
type=raw,value=${{ github.event.inputs.environment }}-latest
- name: Build and push Docker image
uses: docker/build-push-action@v6
with:
@@ -53,7 +67,6 @@ jobs:
file: ./Dockerfile
push: true
platforms: linux/amd64
tags: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.meta.outputs.tag }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
no-cache: true

View File

@@ -2,6 +2,8 @@
All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines.
## [1.6.7](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.6.6...v1.6.7) (2026-03-04)
## [1.6.6](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.6.5...v1.6.6) (2026-03-03)

View File

@@ -1,6 +1,6 @@
{
"name": "hipmi",
"version": "1.6.6",
"version": "1.6.7",
"private": true,
"prisma": {
"seed": "bun prisma/seed.ts"

View File

@@ -4,9 +4,9 @@ declare global {
var prisma: PrismaClient | undefined;
}
if (!process.env.DATABASE_URL) {
throw new Error("DATABASE_URL is required but not found in environment variables");
}
// if (!process.env.DATABASE_URL) {
// throw new Error("DATABASE_URL is required but not found in environment variables");
// }
const prisma =
global.prisma ??