Skip to content
Open
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
2 changes: 2 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ mise run install
| ------------------- | -------------------------------------------------------- |
| `mise run build` | Fetch every source and build the site into `site/dist` |
| `mise run serve` | Serve the built site at <http://127.0.0.1:4410/docs/> |
| `mise run website` | Build the site and add the landing page into `build/website` |
| `mise run serve-website` | Serve the website at <http://127.0.0.1:4410/> |
| `mise run assemble` | Fetch and assemble the sources without building the site |
| `mise run test` | Run the assembler's unit tests |
| `mise run lint` | Check formatting and lint with [Biome](https://biomejs.dev/) |
Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ previews for source repositories are tracked in

To publish a new release, add its tag to `sources.yml`.

The published website serves a small landing page from [`www/`](www/)
at `/` and the docs at `/docs/`. [`scripts/website.mjs`](scripts/website.mjs)
combines the two after the docs build.

## Run it locally

```shell
Expand Down
9 changes: 9 additions & 0 deletions mise.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,15 @@ depends = ["assemble"]
env = { BASE_PATH = "/docs/" }
run = "npm run site"

[tasks.website]
description = "Build the site, then add the landing page at / with the docs at /docs/"
depends = ["build"]
run = "npm run website"

[tasks.serve-website]
description = "Serve the website at http://127.0.0.1:4410/"
run = "node scripts/serve.mjs build/website 4410 /"

[tasks.test]
description = "Run the unit tests for the assembler"
run = "npm test"
Expand Down
12 changes: 7 additions & 5 deletions netlify.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
# SPDX-License-Identifier: Apache-2.0

# Netlify build settings. These override the settings in the Netlify UI.
# `npm run build` fetches the sources and assembles the pages before
# building the site; `npm run site` alone expects them to be assembled already.
# Netlify serves the site at the root, so BASE_PATH stays unset.
# `npm run build` fetches the sources and builds the docs under /docs/;
# `npm run website` then puts the landing page at / and the docs at /docs/.

[build]
command = "npm run build"
publish = "site/dist"
command = "npm run build && npm run website"
publish = "build/website"

[build.environment]
BASE_PATH = "/docs/"
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
"sync": "node site/scripts/sync.mjs",
"build": "npm run assemble && npm run site",
"site": "npm run sync && astro build --root site && node scripts/redirects.mjs site/dist",
"website": "node scripts/website.mjs site/dist build/website",
"dev": "npm run sync && astro dev --root site",
"lint": "biome ci --error-on-warnings .",
"format": "biome check --write .",
Expand Down
29 changes: 29 additions & 0 deletions scripts/website.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#!/usr/bin/env node
// SPDX-License-Identifier: Apache-2.0
// Assemble the website: the files in www/ (the landing page) at / and the
// docs build at /docs/.
// The docs build must use BASE_PATH=/docs/ so its links resolve under /docs/.
// Usage: node scripts/website.mjs site/dist build/website
import fs from 'node:fs';
import path from 'node:path';

const MOUNT = 'docs';
const [docs = 'site/dist', out = 'build/website'] = process.argv.slice(2).map((p) => path.resolve(p));
const repo = path.resolve(import.meta.dirname, '..');

const { base } = JSON.parse(fs.readFileSync(path.join(docs, 'versions.json'), 'utf8'));
if (base !== `/${MOUNT}/`) {
console.error(`${docs} was built with base ${base}; rebuild it with BASE_PATH=/${MOUNT}/`);
process.exit(1);
}

fs.rmSync(out, { recursive: true, force: true });
fs.cpSync(path.join(repo, 'www'), out, { recursive: true });
fs.copyFileSync(path.join(repo, 'theme/tokens.css'), path.join(out, 'tokens.css'));
for (const f of ['favicon.svg', 'apple-touch-icon.png', 'cncf'])
fs.cpSync(path.join(repo, 'site/static', f), path.join(out, f), { recursive: true });
fs.cpSync(docs, path.join(out, MOUNT), { recursive: true });
// Hosts serve /404.html for any missing path. The docs one links its assets
// absolutely (/docs/_astro/...), so it works at the root too.
fs.copyFileSync(path.join(docs, '404.html'), path.join(out, '404.html'));
console.log(`website -> ${path.relative(process.cwd(), out)} (landing at /, docs at /${MOUNT}/)`);
234 changes: 234 additions & 0 deletions www/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,234 @@
<!doctype html>
<!-- SPDX-License-Identifier: Apache-2.0 -->
<!-- The landing page at /. Everything in www/ is served at the site root; scripts/website.mjs publishes it next to the docs build at /docs/. -->
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<title>OpenShell</title>
<meta name="description" content="The safe, private runtime for autonomous AI agents." />
<link rel="icon" href="/favicon.svg" type="image/svg+xml" />
<link rel="apple-touch-icon" href="/apple-touch-icon.png" />
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
<link
rel="stylesheet"
href="https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600;700&family=Geist+Mono:wght@400;500&display=swap"
/>
<link rel="stylesheet" href="/tokens.css" />
<link rel="stylesheet" href="/style.css" />
<script>
// Share the theme choice with the docs: Starlight stores it as starlight-theme.
(() => {
let t = '';
try {
t = localStorage.getItem('starlight-theme') ?? '';
} catch {}
if (t !== 'light' && t !== 'dark') t = matchMedia('(prefers-color-scheme: light)').matches ? 'light' : 'dark';
document.documentElement.dataset.theme = t;
})();
</script>
</head>
<body>
<header class="top">
<a href="/" class="wordmark" translate="no">
<svg viewBox="14 7 72 87" aria-hidden="true">
<path d="M50 9 L84 23 V51 C84 72 69 86 50 92 C31 86 16 72 16 51 V23 Z" fill="#76B900" />
<g fill="none" stroke="#FFFFFF" stroke-width="6" stroke-linecap="round" stroke-linejoin="round">
<path d="M37 41 L49 50 L37 59" />
<path d="M55 59 H67" />
</g>
</svg>
<span>OpenShell</span>
</a>
<nav aria-label="Site">
<a href="/docs/" class="nav-link">Docs</a>
<a href="https://github.com/ai-openshell/openshell" class="icon-link">
<span class="sr-only">GitHub</span>
<svg viewBox="0 0 24 24" aria-hidden="true">
<path
fill="currentColor"
d="M12 .3a12 12 0 0 0-3.8 23.38c.6.12.83-.26.83-.57L9 21.07c-3.34.72-4.04-1.61-4.04-1.61-.55-1.39-1.34-1.76-1.34-1.76-1.08-.74.09-.73.09-.73 1.2.09 1.83 1.24 1.83 1.24 1.07 1.83 2.81 1.3 3.5 1 .1-.78.42-1.31.76-1.6-2.67-.3-5.47-1.33-5.47-5.93 0-1.31.47-2.38 1.24-3.22-.14-.3-.54-1.52.1-3.18 0 0 1-.32 3.3 1.23a11.5 11.5 0 0 1 6 0c2.28-1.55 3.29-1.23 3.29-1.23.64 1.66.24 2.88.12 3.18a4.65 4.65 0 0 1 1.23 3.22c0 4.61-2.8 5.63-5.48 5.92.42.36.81 1.1.81 2.22l-.01 3.29c0 .31.2.69.82.57A12 12 0 0 0 12 .3"
/>
</svg>
</a>
<button type="button" class="icon-link theme-toggle" aria-label="Toggle dark mode">
<svg viewBox="0 0 24 24" aria-hidden="true" class="sun">
<circle cx="12" cy="12" r="4" fill="none" stroke="currentColor" stroke-width="1.75" />
<path
d="M12 2v2M12 20v2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M2 12h2M20 12h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4"
stroke="currentColor"
stroke-width="1.75"
stroke-linecap="round"
/>
</svg>
<svg viewBox="0 0 24 24" aria-hidden="true" class="moon">
<path
d="M20 14.5A8 8 0 0 1 9.5 4a8 8 0 1 0 10.5 10.5Z"
fill="none"
stroke="currentColor"
stroke-width="1.75"
stroke-linejoin="round"
/>
</svg>
</button>
</nav>
</header>

<main>
<!-- Copy comes from the ai-openshell/openshell README (intro, How It Works,
Quickstart, Explore Further) and the repository description. Keep it in sync
rather than writing new copy here. -->
<section class="hero">
<h1>The safe, private runtime for <span class="accent">autonomous AI agents</span></h1>
<p class="lede">
Agents are most useful when they can read files, install packages, call APIs, and use credentials. OpenShell
gives them that capability without giving them unrestricted access to your data, secrets, or network. You
declare what each agent can touch in a policy, and OpenShell enforces it.
</p>
<div class="actions">
<a class="button primary" href="/docs/">Documentation <span aria-hidden="true">→</span></a>
<a class="button" href="https://github.com/ai-openshell/openshell">GitHub</a>
</div>
</section>

<section class="install" aria-labelledby="install-title">
<h2 id="install-title">Quickstart</h2>
<p class="section-lede">
You need Linux, macOS on Apple Silicon, or Windows with WSL 2 (experimental), plus Docker, Podman, or host
virtualization. See the <a href="/docs/about/support-matrix/">Support Matrix</a> for details.
</p>
<figure class="terminal">
<figcaption><span class="sr-only">Terminal window</span></figcaption>
<div class="cmd">
<code
><span class="t-fn">curl</span> <span class="t-flag">-LsSf</span>
<span class="t-str">https://raw.githubusercontent.com/ai-openshell/openshell/main/install.sh</span>
<span class="t-op">|</span> <span class="t-fn">sh</span></code
>
<button
type="button"
class="copy"
data-code="curl -LsSf https://raw.githubusercontent.com/ai-openshell/openshell/main/install.sh | sh"
aria-label="Copy install command"
></button>
</div>
<div class="cmd">
<code
><span class="t-fn">openshell</span> sandbox create <span class="t-flag">--name</span> demo</code
>
<button
type="button"
class="copy"
data-code="openshell sandbox create --name demo"
aria-label="Copy sandbox command"
></button>
</div>
</figure>
<p class="note">
The installer sets up the CLI and a local gateway. The default sandbox image is minimal Ubuntu with no agent
installed. To run a real agent, follow
<a href="/docs/about/run-your-first-agent/">Run Your First Agent</a>: it runs OpenCode against a free
OpenRouter model and shows how to approve new access as the agent needs it.
</p>
</section>

<section class="features" aria-labelledby="how-title">
<h2 id="how-title">How It Works</h2>
<p class="section-lede">
OpenShell governs what agents can do in two ways: it instruments the kernel to enforce policy on every file
access, system call, and network connection at runtime, and it uses formal verification to check what a policy
change would allow before it is applied.
</p>
<div class="cards">
<div class="card">
<span class="card-title">Kernel-level enforcement</span>
<span class="card-body"
>Each agent runs in an isolated sandbox. Kernel controls confine which files it can access and which system
calls it can make, and every network connection passes through a policy check before it leaves the sandbox.
Agents never see real credentials; OpenShell adds them only to requests bound for approved endpoints.</span
>
</div>
<div class="card">
<span class="card-title">Formally verified policy changes</span>
<span class="card-body"
>Before a policy change is approved, OpenShell uses formal verification to flag risky new access it would
grant, such as reaching a new host with credentials or calling a new API method, so those changes wait for
human review.</span
>
</div>
</div>
<p class="note">
See <a href="/docs/about/architecture/">Architecture</a> for how the gateway, supervisor, and sandbox fit
together.
</p>
</section>

<section class="features" aria-labelledby="explore-title">
<h2 id="explore-title">Explore Further</h2>
<div class="cards">
<a class="card" href="/docs/how-it-works/sandboxes/overview/">
<span class="card-title">Sandboxes <span class="arrow" aria-hidden="true">→</span></span>
<span class="card-body">Images, runtimes, GPUs, and lifecycle.</span>
</a>
<a class="card" href="/docs/how-it-works/policies/overview/">
<span class="card-title">Policies <span class="arrow" aria-hidden="true">→</span></span>
<span class="card-body"
>Filesystem, network, and process rules, with the advisor and prover for reviewing changes.</span
>
</a>
<a class="card" href="/docs/how-it-works/providers/overview/">
<span class="card-title">Providers <span class="arrow" aria-hidden="true">→</span></span>
<span class="card-body">Credentials that work only at approved endpoints, including inference.</span>
</a>
<a class="card" href="/docs/how-it-works/gateways/overview/">
<span class="card-title">Gateways <span class="arrow" aria-hidden="true">→</span></span>
<span class="card-body">The control plane for sandboxes, policy, and access.</span>
</a>
<a class="card" href="/docs/kubernetes/setup/">
<span class="card-title">Kubernetes <span class="arrow" aria-hidden="true">→</span></span>
<span class="card-body">Deploy the gateway with Helm. Your CNI must enforce <code>NetworkPolicy</code>.</span>
</a>
<a class="card" href="/docs/extensibility/overview/">
<span class="card-title">Extensibility <span class="arrow" aria-hidden="true">→</span></span>
<span class="card-body">Middleware, interceptors, and compute drivers.</span>
</a>
</div>
</section>
</main>

<footer class="cncf">
<p>We are a <a href="https://www.cncf.io/">Cloud Native Computing Foundation</a> sandbox project.</p>
<a href="https://www.cncf.io/" class="cncf-logo">
<img src="/cncf/cncf-color.svg" alt="Cloud Native Computing Foundation" class="light-only" width="200" height="38" />
<img src="/cncf/cncf-white.svg" alt="Cloud Native Computing Foundation" class="dark-only" width="200" height="38" />
</a>
<p class="legal">
Copyright OpenShell a Series of LF Projects, LLC<br />
For website terms of use, trademark policy and other project policies please see
<a href="https://lfprojects.org/policies/">lfprojects.org/policies/</a>.
</p>
</footer>

<script>
for (const b of document.querySelectorAll('button.copy')) {
b.addEventListener('click', async () => {
try {
await navigator.clipboard.writeText(b.dataset.code);
} catch {
return;
}
b.dataset.copied = '';
setTimeout(() => delete b.dataset.copied, 1500);
});
}
document.querySelector('.theme-toggle').addEventListener('click', () => {
const t = document.documentElement.dataset.theme === 'dark' ? 'light' : 'dark';
document.documentElement.dataset.theme = t;
try {
localStorage.setItem('starlight-theme', t);
} catch {}
});
</script>
</body>
</html>
Loading
Loading