Skip to content

Commit 2f4ca98

Browse files
icecrasher321claude
andcommitted
fix(docs): describe which surfaces the NEXT_PUBLIC_ flag twins still gate
The workspace host context now carries the server-resolved deployment shape, so settings sections and block fields inside a workspace follow the server variable. The NEXT_PUBLIC_ twins still gate the login page's SSO entry point and the Function block's Sandbox selector, and sim-setup doctor checks each pair. Update the sentences that said the twin decides what the settings UI shows. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
1 parent 71e848a commit 2f4ca98

6 files changed

Lines changed: 10 additions & 10 deletions

File tree

‎apps/docs/content/docs/platform/enterprise/data-drains.mdx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ DATA_DRAINS_ENABLED=true
237237
NEXT_PUBLIC_DATA_DRAINS_ENABLED=true
238238
```
239239

240-
`NEXT_PUBLIC_DATA_DRAINS_ENABLED` shows the **Settings → Organization → Data drains** page in the UI. `DATA_DRAINS_ENABLED` gates the server-side mutating endpoints and the cron dispatcher — when unset on a self-hosted deployment, drain create/update/delete/run requests return `404` and the dispatcher is a no-op. Both should be set to `true` together.
240+
`DATA_DRAINS_ENABLED` shows the **Settings → Organization → Data drains** page and gates the server-side mutating endpoints and the cron dispatcher — when unset on a self-hosted deployment, the page is hidden, drain create/update/delete/run requests return `404`, and the dispatcher is a no-op. Set `NEXT_PUBLIC_DATA_DRAINS_ENABLED` to the same value so the browser's configuration matches the server's; `npx sim-setup doctor` reports the pair disagreeing.
241241

242242
### Scheduling the dispatcher
243243

‎apps/docs/content/docs/platform/enterprise/self-hosted.mdx‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ There are two parts to getting this right, and skipping the second is the most c
1616

1717
## Enable the feature set
1818

19-
Set the master switch and its client twin. Both are required — the server value decides access, and the `NEXT_PUBLIC_` value decides what the settings UI shows.
19+
Set the master switch and its client twin. Both are required. The server value decides access and what a workspace shows: settings sections and block fields read the deployment's server-resolved configuration, so the sidebar and the API answer the same question. The `NEXT_PUBLIC_` value covers what renders before a workspace loads — the SSO entry point on the login page — and `npx sim-setup doctor` reports any pair that disagrees.
2020

2121
```bash
2222
ENTERPRISE_ENABLED=true
@@ -59,7 +59,7 @@ Three features do not need a flag at all: **custom branding**, **session policie
5959
| Sim Mailer inbox — on by default | `INBOX_ENABLED` | `NEXT_PUBLIC_INBOX_ENABLED` |
6060
| Sandboxes | `SANDBOXES_ENABLED` | `NEXT_PUBLIC_SANDBOXES_ENABLED` |
6161

62-
Sandboxes also need a remote execution provider and a dedicated Function base image before they can run anything. `SANDBOXES_ENABLED` grants the server-side entitlement; `NEXT_PUBLIC_SANDBOXES_ENABLED` projects provider readiness to the browser and exposes Shell plus custom Sandbox management. Set the public flag only after the selected provider has credentials and a valid immutable Function base configured.
62+
Sandboxes also need a remote execution provider and a dedicated Function base image before they can run anything. `SANDBOXES_ENABLED` grants the server-side entitlement, and Shell and **Settings → Sandboxes** appear only once the server has also verified the provider credentials and an immutable Function base. `NEXT_PUBLIC_SANDBOXES_ENABLED` is the browser's copy of that readiness: it reveals the Function block's Sandbox selector, and `npx sim-setup doctor` checks it against the server. Set it only after the selected provider has credentials and a valid immutable Function base configured.
6363

6464
JavaScript without `import` or `require` does not use the remote provider and continues to run in the local isolated VM when all Sandbox flags are off. Python, Shell, JavaScript with external imports, and selected custom Sandboxes fail with an explicit configuration error until the remote Function base is ready.
6565

@@ -249,9 +249,9 @@ curl -X DELETE "https://sim.example.com/api/v1/admin/organizations/$ORG_ID?confi
249249

250250
If a feature is enabled but nothing appears, check these in order.
251251

252-
**The settings section is missing.** The `NEXT_PUBLIC_` twin is not set, or the app was not restarted after adding it. Client variables are read at boot from the container environment, so a restart is enough — no rebuild.
252+
**The settings section is missing.** The server-side variable is not set, or the app was not restarted after adding it. Variables are read at boot from the container environment, so a restart is enough — no rebuild.
253253

254-
**The section appears but the API returns 403.** The server-side variable is missing while its client twin is set. Set both.
254+
**The section appears but the login page has no SSO option, or the Function block has no Sandbox selector.** The `NEXT_PUBLIC_` twin is missing while the server-side variable is set. A workspace follows the server, but the login page renders before any workspace loads and reads the twin, and the Sandbox selector does too. Set both; `npx sim-setup doctor` reports the pair disagreeing.
255255

256256
**The feature is on but has no effect inside a workspace.** The workspace is not owned by an organization. Check `workspace_mode` and `organization_id`:
257257

‎apps/docs/content/docs/platform/enterprise/verified-domains.mdx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,6 @@ SSO_ENABLED=true
7171
NEXT_PUBLIC_SSO_ENABLED=true
7272
```
7373

74-
`ENTERPRISE_ENABLED` turns both on together, but it needs its own browser twin — set `NEXT_PUBLIC_ENTERPRISE_ENABLED` alongside it, or the server enables SSO while the browser still hides it. See the [self-hosted enterprise guide](/platform/enterprise/self-hosted).
74+
`ENTERPRISE_ENABLED` turns both on together, but it needs its own browser twin — set `NEXT_PUBLIC_ENTERPRISE_ENABLED` alongside it, or the server and the settings page enable SSO while the login page still hides its SSO entry point. See the [self-hosted enterprise guide](/platform/enterprise/self-hosted).
7575

7676
Once enabled, verify domains from **Settings → Organization → Single sign-on**, in the **Verified domains** section above the identity provider configuration. The older `/workspace/<workspaceId>/settings/domains` path still resolves to the same page.

‎apps/docs/content/docs/platform/self-hosting/environment-variables.mdx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ Who may sign up and sign in — the allowlists, blocklists, `DISABLE_REGISTRATIO
144144
| `E2B_FUNCTION_TEMPLATE_GENERATION` | Monotonic release generation printed by the same build. Required for E2B |
145145
| `DAYTONA_FUNCTION_SNAPSHOT_ID` | Immutable snapshot **ID** (not a name) for the Function base image. Required for Daytona |
146146
| `E2B_PI_TEMPLATE_ID` / `DAYTONA_PI_SNAPSHOT_ID` | The image Pi runs on. Separate from the Function base — configuring the provider and Function image alone leaves Pi failing closed |
147-
| `SANDBOXES_ENABLED` / `NEXT_PUBLIC_SANDBOXES_ENABLED` | Enable custom sandboxes on a self-hosted deployment, bypassing the hosted-plan requirement. Neither is sufficient on its own — a provider key **and** an immutable Function base must also be configured. Set the `NEXT_PUBLIC_` twin only after the server side works; it asserts readiness to the browser rather than enabling anything |
147+
| `SANDBOXES_ENABLED` / `NEXT_PUBLIC_SANDBOXES_ENABLED` | Enable custom sandboxes on a self-hosted deployment, bypassing the hosted-plan requirement. Neither is sufficient on its own — a provider key **and** an immutable Function base must also be configured. Set the `NEXT_PUBLIC_` twin only after the server side works; it enables nothing by itself — it reveals the Function block's Sandbox selector and lets `sim-setup doctor` confirm the two sides agree |
148148
| `IVM_MAX_EXECUTIONS_PER_WORKER` | Executions before an isolated-vm worker is recycled |
149149
| `IVM_MAX_BROKERS_PER_EXECUTION` | Host-call brokers per execution |
150150
| `IVM_MAX_BROKER_ARGS_JSON_CHARS` | Max argument payload size |

‎apps/docs/content/docs/platform/self-hosting/sandboxes.mdx‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ Until the base image is configured, those languages fail with an explicit config
1515
| Variable | Purpose |
1616
| --- | --- |
1717
| `SANDBOXES_ENABLED` | Grants the server-side self-hosted entitlement |
18-
| `NEXT_PUBLIC_SANDBOXES_ENABLED` | Projects provider readiness to the browser and exposes Shell plus custom sandbox management |
18+
| `NEXT_PUBLIC_SANDBOXES_ENABLED` | The browser's copy of provider readiness. Reveals the Function block's Sandbox selector; `sim-setup doctor` checks it against the server |
1919

20-
`NEXT_PUBLIC_SANDBOXES_ENABLED` is a browser gate only: it shows or hides Shell, the sandbox picker, and **Settings → Sandboxes**. Whether Python or a selected sandbox actually runs depends on the server-side provider and Function image. Set it only after those work, or you surface controls that cannot.
20+
Shell and **Settings → Sandboxes** follow the server: a workspace shows them only when `SANDBOXES_ENABLED` is set and the server has verified the provider credentials and an immutable Function base. `NEXT_PUBLIC_SANDBOXES_ENABLED` is a browser gate for one control, the Function block's Sandbox selector. Whether Python or a selected sandbox actually runs depends on the server-side provider and Function image, so set it only after those work, or you surface a selector for sandboxes that cannot run.
2121

2222
## Building the Function base
2323

‎apps/docs/content/docs/platform/self-hosting/security.mdx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ Two browser-side variables project server state into the UI, and neither is deri
151151

152152
| Variable | Effect when unset |
153153
|---|---|
154-
| `NEXT_PUBLIC_SANDBOXES_ENABLED` | The Function block's Shell language, its Sandbox picker, and **Settings → Sandboxes** stay hidden, even with a working provider. Python stays selectable; whether it runs depends on the server-side provider and Function image, not on this flag |
154+
| `NEXT_PUBLIC_SANDBOXES_ENABLED` | The Function block's Sandbox selector stays hidden, even with a working provider. Shell and **Settings → Sandboxes** are unaffected — a workspace shows them from the server's own readiness check. Python stays selectable; whether it runs depends on the server-side provider and Function image, not on this flag |
155155
| `NEXT_PUBLIC_E2B_ENABLED` | The E2B-backed Pi block modes stay hidden; `sim-setup doctor` reports it as a mismatch against `E2B_ENABLED`. Revealing them is not enough to make them run — Pi executes on its own image, pinned with `E2B_PI_TEMPLATE_ID` or `DAYTONA_PI_SNAPSHOT_ID`, and fails closed without it |
156156

157157
Set the public values only **after** the server-side configuration above is complete — they are assertions about readiness, not switches, and the server-side check has its own conditions beyond them. See [Sandboxes](/platform/self-hosting/sandboxes) for the base-image build and promotion procedure. `npx sim-setup doctor` reports a mismatch in either direction.

0 commit comments

Comments
 (0)