Skip to content

Build

Build #83

Workflow file for this run

name: Build
on:
# Runs on pushes targeting the default branch
push:
branches: ["main"]
release:
types: [published]
schedule:
- cron: "17 * * * *"
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
# Build job
build:
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: "10.28.1"
- name: Setup Node
uses: actions/setup-node@v5
with:
node-version: "22"
cache: pnpm
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Refresh GitHub release data
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
GITHUB_TOKEN: ${{ github.token }}
run: pnpm run sync:releases
- name: Show fetched release versions
run: pnpm run report:releases
- name: Static HTML export with Next.js
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
GITHUB_TOKEN: ${{ github.token }}
run: pnpm run build
- name: Export release version manifest
run: pnpm run report:releases -- --write out/release-versions.json
- name: Upload to Bucket
env:
OSS_BUCKET: rustfs-artifacts
OSS_KEY_ID: ${{ secrets.ALICLOUDOSS_KEY_ID }}
OSS_KEY_SECRET: ${{ secrets.ALICLOUDOSS_KEY_SECRET }}
OSS_REGION: oss-cn-beijing
OSS_SOURCE_DIR: out
run: pnpm run upload:oss