0b6ac9cBuild and publish the site from the vault's CI on every push to mainJeremy Magland 1# Build the page and publish it as this repository's site, on every push to
2# main. The site lands at /tutorials/laplace-dirichlet/site/.
3#
4# Two cofferdam-specific points. `actions/cache` is not implemented, so
5# `setup-node` must not be given `cache: npm`; the install is done cold every
6# run. And the site is served from a sub-path rather than a domain root, which
7# is why vite.config.ts sets `base: './'` — the build emits relative URLs and
8# needs no base path passed in.
9name: site
11on:
12 push:
13 branches: [main]
14 workflow_dispatch:
16concurrency:
17 group: site
18 cancel-in-progress: false
20jobs:
21 build:
22 runs-on: ubuntu-latest
23 steps:
24 - uses: actions/checkout@v4
26 - uses: actions/setup-node@v4
27 with:
28 node-version: 22
30 # puppeteer is only used by scripts/browser-test.mjs, which does not run
31 # here; skip the ~150 MB Chrome download
32 - run: npm ci
33 env:
34 PUPPETEER_SKIP_DOWNLOAD: "true"
36 - run: npm run build
38 - uses: actions/upload-pages-artifact@v3
39 with:
40 path: dist
42 - uses: actions/deploy-pages@v4