the build can be pointed at one page

TEMPORARY, and inert unless set. Bisecting a Performance score means a build between every
measurement, and rendering all 48 routes to change one of them is most of the wait.

FOFOS_BUILD_ONLY is passed through to the site's build script, which renders only the listed paths and
— the part that is not optional — skips the prune at the swap. The swap deletes anything in dist/ that
the run did not stage, so a one-page build would otherwise take every other page of the live site with
it, 404 until the next full build.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-08-29 23:12:50 +01:00
co-authored by Claude Opus 5
parent 3b962fe3ca
commit c5fe7c0f86
+3
View File
@@ -160,6 +160,9 @@ export async function buildSite(secrets: {
FOFOS_API_TOKEN: secrets.apiToken,
ADMIN_SESSION_SECRET: secrets.sessionSecret,
FOFOS_MEDIA_DIR: join(row.rootPath, 'media'),
// TEMPORARY — passed through so a bisect can rebuild one page instead of all 48. The site's
// build script leaves every other page alone when this is set. Unset, nothing changes.
...(process.env.FOFOS_BUILD_ONLY ? { FOFOS_BUILD_ONLY: process.env.FOFOS_BUILD_ONLY } : {}),
// Only used to build absolute URLs in the output — og:image, canonical links. The real domain
// belongs in the checkout's own env, where it is a deployment fact rather than one this invented.
PUBLIC_URL: process.env.FOFOS_PUBLIC_URL ?? 'http://127.0.0.1',