Skip to content

Test publishing GitHub Pages from branch #1

Test publishing GitHub Pages from branch

Test publishing GitHub Pages from branch #1

Workflow file for this run

# Builds the web configurator (web/) and deploys it to GitHub Pages.
#
# One-time repo setup:
# Settings → Pages → Build and deployment → Source = "GitHub Actions".
# The site is served at https://<owner>.github.io/<repo>/ — vite.config.ts uses
# base "./" (relative paths) so it works from that subpath without further config.
name: Deploy web configurator
on:
push:
# TEMPORARY: web-configurator is included so Pages can be tested from the branch
# before merge. Revert to `branches: [main]` once verified.
branches: [main, web-configurator]
paths:
- "web/**"
- ".github/workflows/deploy-web.yml"
# Allow manual runs from the Actions tab.
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
# Allow only one concurrent deployment; let an in-progress run finish.
concurrency:
group: pages
cancel-in-progress: false
jobs:
build:
runs-on: ubuntu-24.04
defaults:
run:
working-directory: web
steps:
- uses: actions/checkout@v4
# Keep this version in sync with the Dockerfile's Bun install.
- uses: oven-sh/setup-bun@v2
with:
bun-version: 1.3.14
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Run tests
run: bun run test
# `bun run build` runs vue-tsc --noEmit then vite build, so this also typechecks.
- name: Build
run: bun run build
- uses: actions/configure-pages@v5
- uses: actions/upload-pages-artifact@v3
with:
path: web/dist
deploy:
needs: build
runs-on: ubuntu-24.04
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- id: deployment
uses: actions/deploy-pages@v4