Files
openwork/apps/app/src/app/app-settings/feature-flags-preferences.ts
ben 800602f4e3 feat: add microsandbox sandbox flow and feature flag toggle (#1446)
* add pre-baked microsandbox image

Bake openwork, openwork-server, and the pinned opencode binary into a single Docker image so micro-sandbox remote-connect smoke tests can boot quickly and be verified with curl and container health checks.

* add Rust microsandbox example

Add a standalone microsandbox SDK example that boots the OpenWork image, validates remote-connect endpoints, and streams sandbox logs so backend-only sandbox behavior can be exercised without Docker.

* exclude Rust example build output

Keep the standalone microsandbox example in git, but drop generated Cargo target artifacts so the branch only contains source, docs, and lockfile.

* test

* add microsandbox feature flag for sandbox creation

Made-with: Cursor

* refactor sandbox mode isolation

Made-with: Cursor
2026-04-15 15:10:52 -07:00

18 lines
477 B
TypeScript

import { useLocal } from "../context/local";
export function useFeatureFlagsPreferences() {
const { prefs, setPrefs } = useLocal();
const microsandboxCreateSandboxEnabled = () =>
prefs.featureFlags?.microsandboxCreateSandbox === true;
const toggleMicrosandboxCreateSandbox = () => {
setPrefs("featureFlags", "microsandboxCreateSandbox", (current) => !current);
};
return {
microsandboxCreateSandboxEnabled,
toggleMicrosandboxCreateSandbox,
};
}