Skip to content

Commit 6d86462

Browse files
committed
Require opt-in dev admin seeding
1 parent 94c3bd5 commit 6d86462

2 files changed

Lines changed: 7 additions & 2 deletions

File tree

RUNNING.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,9 @@ develop on its `main`, publish a bump, then bump the dependency here. The
3030
- Self-host boots standalone with just env vars — see
3131
`e2e/setup/selfhost.globalsetup.ts` for the canonical recipe (data dir,
3232
bootstrap admin email/password, base URL, `EXECUTOR_ALLOW_LOCAL_NETWORK`)
33+
- Self-host Vite dev shows first-run setup by default. Set
34+
`EXECUTOR_DEV_SEED_ADMIN=1` to seed `admin@example.com` /
35+
`executor-dev-admin` instead.
3336
- Cloud needs WorkOS + Autumn; for a no-.env boot, point it at emulators —
3437
see `e2e/setup/cloud.globalsetup.ts` for the canonical recipe (the real
3538
SDKs against emulated services, PGlite dev DB)

apps/host-selfhost/vite.config.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,10 @@ const DEV_PORT = 5173;
3434
// via real env for anything you care about (esp. BETTER_AUTH_SECRET in prod).
3535
process.env.EXECUTOR_DATA_DIR ??= fileURLToPath(new URL("./.executor-dev/", import.meta.url));
3636
process.env.BETTER_AUTH_SECRET ??= "executor-selfhost-dev-secret-change-me-0123456789";
37-
process.env.EXECUTOR_BOOTSTRAP_ADMIN_EMAIL ??= "admin@example.com";
38-
process.env.EXECUTOR_BOOTSTRAP_ADMIN_PASSWORD ??= "executor-dev-admin";
37+
if (process.env.EXECUTOR_DEV_SEED_ADMIN === "1") {
38+
process.env.EXECUTOR_BOOTSTRAP_ADMIN_EMAIL ??= "admin@example.com";
39+
process.env.EXECUTOR_BOOTSTRAP_ADMIN_PASSWORD ??= "executor-dev-admin";
40+
}
3941
process.env.EXECUTOR_WEB_BASE_URL ??= `http://localhost:${DEV_PORT}`;
4042

4143
// Dev-only: forward /api, /mcp, /docs to the self-host Effect handler in-process

0 commit comments

Comments
 (0)