Skip to content
Draft
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
13 changes: 8 additions & 5 deletions .github/workflows/baseline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,15 +81,18 @@ jobs:
- uses: actions/checkout@v6
- uses: sourceplane/orun-action@v1.2.0
with:
# The bootstrap floor (BOOTSTRAP.md), not the product lane pin. It
# used to be v2.58.11 — the first CLI that could read this document
# at all (`orun.run/watch@v1`'s `sha:`, a landing's whole-run check
# wait, `githubOwner`, `environments`, a deferred project probe, and
# Pinned at v2.96.0, not the product lane pin: at or above the
# bootstrap floor (v2.88.0, BOOTSTRAP.md), and the first orun that
# reads a component's `spec.preview`, so the placement's `orun
# validate` checks the console's live preview too. The floor used to
# be v2.58.11 — the first CLI that could read this document at all
# (`orun.run/watch@v1`'s `sha:`, a landing's whole-run check wait,
# `githubOwner`, `environments`, a deferred project probe, and
# `from: workspace`). It is v2.88.0 now, for three keys an older CLI
# refuses at parse: `hooks.preInstantiate[].background`,
# `orun.pr/land@v1`'s `checks: local`, and
# `orun.integrations/reconcile@v1`'s `secrets:` list (v2.87.0).
version: v2.88.0
version: v2.96.0
- name: repo-blueprint.yaml, read by the pinned CLI
run: |
set -euo pipefail
Expand Down
26 changes: 26 additions & 0 deletions apps/web-console-next/component.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,32 @@ spec:
- profile: deploy
when:
triggerRef: github-push-main
# How the console runs itself for orun.work's live Preview tab
# (saas-parallel-baselining PB4): `orun preview` starts this, and a coding
# session keeps it running while it works, so the person watches it change
# as it is built. The dev server binds the box's loopback only, on a fixed
# port, and installs first, so a checkout the session has not installed yet
# still comes up.
# Kept small on purpose, for looking at the UI inside the session's own box:
# the console alone, `next dev` on the loopback, and no `needs`, so none of
# the twelve workers, the API edge, Supabase or wrangler start. Its API is
# the product's deployed STAGE (CONSOLE_DEPLOY_ENV=stage picks it from the
# committed app config, as a stage deploy does); only the console's own
# packages are installed (`--filter ...`); `next` itself runs, not `pnpm
# exec next`; and its heap is capped at 1 GiB, so it can never starve the
# agent. The token-free pages (the landing page, /login, /demo) show in
# full; pages behind sign-in show the sign-in prompt.
preview:
run:
- sh
- -c
- pnpm install --frozen-lockfile --prefer-offline --filter "@saas/web-console-next..." && exec node_modules/.bin/next dev -H 127.0.0.1 -p 3001
port: 3001
path: /
env:
CONSOLE_DEPLOY_ENV: stage
NODE_OPTIONS: --max-old-space-size=1024
NEXT_TELEMETRY_DISABLED: "1"
parameters:
nodeVersion: "22"
pnpmVersion: "10.12.1"
Expand Down
10 changes: 10 additions & 0 deletions apps/web-console-next/next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,16 @@ const nextConfig = {
// the build deterministic across Node/ESLint flat-config quirks.
ignoreDuringBuilds: true,
},
experimental: {
// Dev server only: behind orun.work's live Preview the browser's Origin
// is the preview's host while `next dev` sees a local Host, and Next.js
// refuses a Server Action from an origin it is not told about. `next
// build` runs with NODE_ENV=production, so production keeps its
// same-origin check.
...(process.env.NODE_ENV === "development"
? { serverActions: { allowedOrigins: ["*.orun-preview.app", "preview-gateway-stage.oruncloud.workers.dev"] } }
: {}),
},
env: {
NEXT_PUBLIC_DEPLOY_ENV: process.env.NEXT_PUBLIC_DEPLOY_ENV ?? "",
// M0 / Solo profile (Lumen ships single-user). Build with
Expand Down
7 changes: 7 additions & 0 deletions intent.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,13 @@ compositions:
cloudflare-domain: stack-tectonic
db-migrate: stack-tectonic

# The live preview (saas-parallel-baselining PB4): the component orun.work's
# Preview tab shows while a coding session works on the console. Its own
# `spec.preview` (apps/web-console-next/component.yaml) says how it runs; `orun preview`
# runs it.
preview:
component: web-console-next

discovery:
roots:
- apps/
Expand Down
Loading