Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: disable swc minify and add babelrc to fix container image release #57

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 21 additions & 19 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ name: release
on:
push:
tags: ['v*.*.*']
branches:
- 52-fix-container-image-release-workflow-is-not-working
workflow_dispatch:
inputs:
version:
Expand All @@ -16,26 +18,26 @@ permissions:
issues: write

jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- run: git fetch --force --tags
- uses: actions/setup-go@v5
with:
go-version: '1.23'
- uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# goreleaser:
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v4
# with:
# fetch-depth: 0
# - run: git fetch --force --tags
# - uses: actions/setup-go@v5
# with:
# go-version: '1.23'
# - uses: goreleaser/goreleaser-action@v5
# with:
# distribution: goreleaser
# version: latest
# args: release --clean
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
containerize:
runs-on: ubuntu-latest
needs: goreleaser
# needs: goreleaser
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -45,7 +47,7 @@ jobs:
id: buildx
uses: docker/setup-buildx-action@v3
- name: Login to GHCR
if: github.event_name != 'pull_request'
# if: github.event_name != 'pull_request'
uses: docker/login-action@v3
with:
registry: ghcr.io
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
!ui/public/*
!ui/styles/*
!ui/types/*
!ui/.babelrc
!ui/.eslintrc.json
!ui/.npmrc
!ui/LICENSE
Expand Down
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ WORKDIR /app/ui
COPY ui /app/ui

RUN npm install -g npm@latest && \
npm install --force
npm install -D @swc/cli @swc/core && \
npm install --force --legacy-peer-deps
RUN npm run build

FROM golang:1.23 as backend-builder
Expand Down
4 changes: 4 additions & 0 deletions ui/next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
const nextConfig = {
distDir: 'dist',
output: 'export',
// swcMinify: false,
// experimental: {
// forceSwcTransforms: true,
// },
}

module.exports = nextConfig
Loading