Merge pull request #20 from BlackRoad-OS/codex/update-blackroad-os-docs-frontend
Add structured docs pages and service metadata endpoints
This commit is contained in:
9
.env.example
Normal file
9
.env.example
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
OS_ROOT=https://blackroad.systems
|
||||||
|
SERVICE_BASE_URL=https://docs.blackroad.systems
|
||||||
|
NEXT_PUBLIC_OS_ROOT=https://blackroad.systems
|
||||||
|
NEXT_PUBLIC_SERVICE_ID=docs
|
||||||
|
NEXT_PUBLIC_SERVICE_NAME="BlackRoad OS – Docs"
|
||||||
|
NEXT_PUBLIC_CONSOLE_URL=https://console.blackroad.systems
|
||||||
|
NEXT_PUBLIC_WEB_URL=https://blackroad.systems
|
||||||
|
NEXT_PUBLIC_API_URL=https://api.blackroad.systems
|
||||||
|
PUBLIC_DOCS_URL=https://docs.blackroad.systems
|
||||||
20
Dockerfile
Normal file
20
Dockerfile
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
FROM node:18-alpine AS builder
|
||||||
|
WORKDIR /app
|
||||||
|
COPY package*.json ./
|
||||||
|
RUN npm install
|
||||||
|
COPY . .
|
||||||
|
RUN npm run build
|
||||||
|
|
||||||
|
FROM node:18-alpine AS runner
|
||||||
|
WORKDIR /app
|
||||||
|
COPY package*.json ./
|
||||||
|
RUN npm install --omit=dev
|
||||||
|
COPY --from=builder /app/build ./build
|
||||||
|
COPY --from=builder /app/static ./static
|
||||||
|
COPY --from=builder /app/docusaurus.config.js ./
|
||||||
|
COPY --from=builder /app/sidebars.js ./
|
||||||
|
COPY --from=builder /app/src ./src
|
||||||
|
COPY --from=builder /app/README.md ./
|
||||||
|
ENV PORT=8080
|
||||||
|
EXPOSE 8080
|
||||||
|
CMD ["npm", "start"]
|
||||||
117
README.md
117
README.md
@@ -1,98 +1,39 @@
|
|||||||
# BlackRoad OS Docs
|
# BlackRoad OS – Docs
|
||||||
|
|
||||||
This repository hosts the **BlackRoad OS Handbook**, the production-ready documentation hub for all BlackRoad surfaces (core backend, Web UI, Prism Console, agents, and infrastructure).
|
Documentation portal for the BlackRoad Operating System.
|
||||||
|
|
||||||
## What lives here
|
## Stack
|
||||||
- Structured documentation powered by **Docusaurus v3** (content lives in `docs/`, navigation in `sidebars.js`).
|
- Docusaurus v3 + React
|
||||||
- Opinionated style guide, glossary, and onboarding playbooks.
|
- JavaScript
|
||||||
- Static health/version endpoints generated at build time (`/health.json`, `/version.json`).
|
|
||||||
- CI/CD and deployment workflow definitions for Railway.
|
|
||||||
|
|
||||||
## Getting started
|
## Running locally
|
||||||
1. Install Node 18+ and npm.
|
|
||||||
2. Install dependencies and run the local dev server:
|
|
||||||
```bash
|
```bash
|
||||||
npm install
|
npm install
|
||||||
|
npm run dev
|
||||||
|
```
|
||||||
|
Visit http://localhost:3000 (or the port set in the env).
|
||||||
|
|
||||||
|
## Build & start
|
||||||
|
```bash
|
||||||
|
npm run build
|
||||||
npm start
|
npm start
|
||||||
```
|
```
|
||||||
3. Visit [http://localhost:3000](http://localhost:3000) to browse the docs.
|
The start command serves the static build on port 8080 by default.
|
||||||
|
|
||||||
## Documentation framework & structure
|
## Key routes
|
||||||
- **Framework:** Docusaurus v3 (static site). Routing is rooted at `/` (`routeBasePath: '/'` in `docusaurus.config.js`).
|
- `/` – docs homepage
|
||||||
- **Docs location:** `docs/` organized into the following standard sections:
|
- `/getting-started` – introduction and onboarding checklist
|
||||||
- `intro/`
|
- `/architecture` – high-level architecture overview
|
||||||
- `core/`
|
- `/services` – service catalog
|
||||||
- `web/`
|
- `/api/health` – static health payload
|
||||||
- `console/`
|
- `/api/info` – static service metadata
|
||||||
- `agents/`
|
|
||||||
- `operator/` (stubbed until playbooks are written)
|
|
||||||
- `infra/`
|
|
||||||
- `onboarding/`
|
|
||||||
- **Navigation:** `sidebars.js` defines the tree for the `primarySidebar`. The navbar shows the unified "Docs" sidebar.
|
|
||||||
|
|
||||||
### Adding or updating pages
|
## Railway deployment
|
||||||
1. Add a Markdown file to the correct section in `docs/` (e.g., `docs/core/new-page.md`).
|
- Port: 8080
|
||||||
2. Register it in `sidebars.js` under the matching category so it appears in navigation.
|
- Healthcheck path: `/api/health`
|
||||||
3. Run `npm start` to verify local rendering.
|
- Build command: `npm install && npm run build`
|
||||||
|
- Start command: `npm start`
|
||||||
|
- Required env vars: see `.env.example`
|
||||||
|
|
||||||
### Health & hosting
|
## Environment variables
|
||||||
- The site is static and exposes `static/health.json` and `static/health/index.json` at `/health` and `/health.json` for probes. A version payload lives at `/version` and `/version.json`.
|
Copy `.env.example` and adjust values as needed for your environment. Service URLs default to the production `blackroad.systems` domains.
|
||||||
- The production hostname is controlled through the `PUBLIC_DOCS_URL` env var (see below) and consumed via `src/config/docsConfig.js`.
|
|
||||||
|
|
||||||
### Deployment
|
|
||||||
- The docs build with `npm run build` (includes generating health/version metadata via `scripts/generateMeta.js`).
|
|
||||||
- Deploy to Railway using the provided `railway.json` and GitHub Actions workflow `.github/workflows/docs-deploy.yaml`.
|
|
||||||
- Branch mapping in the workflow:
|
|
||||||
- `dev` → Railway environment `dev` (https://dev.docs.blackroad.systems)
|
|
||||||
- `staging` → Railway environment `staging` (https://staging.docs.blackroad.systems)
|
|
||||||
- `main` → Railway environment `prod` (https://docs.blackroad.systems)
|
|
||||||
The workflow performs a smoke check against `/health` after deployment.
|
|
||||||
|
|
||||||
## Docs Deployment & Environments
|
|
||||||
This repository is the official BlackRoad OS documentation site. It deploys to the Railway project at
|
|
||||||
`https://railway.com/project/a4efb8cd-0d67-4b19-a7f3-b6dbcedf2079?environmentId=a41a126f-ecf9-47b1-8bd6-11ff9a02d799`
|
|
||||||
as the `docs-site` service.
|
|
||||||
|
|
||||||
Environment → URL mapping:
|
|
||||||
- **dev**: https://dev.docs.blackroad.systems (or local http://localhost:3000 via `npm run dev`)
|
|
||||||
- **staging**: https://staging.docs.blackroad.systems
|
|
||||||
- **prod**: https://docs.blackroad.systems
|
|
||||||
|
|
||||||
Required environment variables (loaded via `src/config/docsConfig.js`):
|
|
||||||
- `PUBLIC_DOCS_URL` (required outside of local dev, used for canonical links and metadata)
|
|
||||||
- `NODE_ENV`
|
|
||||||
- Optional cross-link targets: `CORE_API_URL`, `WEB_APP_URL`, `CONSOLE_URL`, `AGENTS_API_URL`
|
|
||||||
|
|
||||||
The `railway.json` file and `.github/workflows/docs-deploy.yaml` workflow keep build (`npm run build`) and start
|
|
||||||
(`npm run start`) commands aligned for deploys, with `/health` configured as the probe path.
|
|
||||||
|
|
||||||
## Related repositories
|
|
||||||
- Core backend: https://github.com/blackroad-os/blackroad-os-core
|
|
||||||
- Web UI: https://github.com/blackroad-os/blackroad-os-web
|
|
||||||
- Prism Console: https://github.com/blackroad-os/blackroad-os-console
|
|
||||||
- Agents runtime: https://github.com/blackroad-os/blackroad-os-agents
|
|
||||||
|
|
||||||
## Infrastructure diagram
|
|
||||||
```mermaid
|
|
||||||
graph TD
|
|
||||||
Docs[Docs Site]
|
|
||||||
Web[Web UI]
|
|
||||||
Console[Prism Console]
|
|
||||||
Core[Core Backend]
|
|
||||||
Agents[Agents Runtime]
|
|
||||||
Railway[(Railway)]
|
|
||||||
Cloudflare[(Cloudflare)]
|
|
||||||
|
|
||||||
Docs --> Cloudflare
|
|
||||||
Web --> Cloudflare
|
|
||||||
Console --> Cloudflare
|
|
||||||
Cloudflare --> Core
|
|
||||||
Core --> Railway
|
|
||||||
Agents --> Core
|
|
||||||
Core --> Agents
|
|
||||||
```
|
|
||||||
|
|
||||||
## Contributing
|
|
||||||
- Follow the style rules in [`docs/style-guide.md`](docs/style-guide.md).
|
|
||||||
- Keep environment tables in [`docs/infra/env-reference.md`](docs/infra/env-reference.md) aligned with the latest `.env.example` files across repos.
|
|
||||||
- Use `npx docusaurus docs:version <version>` when cutting a new release snapshot.
|
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "docusaurus start",
|
"dev": "docusaurus start",
|
||||||
"build": "npm run generate:meta && docusaurus build",
|
"build": "npm run generate:meta && docusaurus build",
|
||||||
"start": "docusaurus serve --dir build --host 0.0.0.0 --port ${PORT:-3000}",
|
"start": "docusaurus serve --dir build --host 0.0.0.0 --port ${PORT:-8080}",
|
||||||
"serve": "npm run start",
|
"serve": "npm run start",
|
||||||
"test": "npm run build",
|
"test": "npm run build",
|
||||||
"generate:meta": "node scripts/generateMeta.js"
|
"generate:meta": "node scripts/generateMeta.js"
|
||||||
|
|||||||
20
railway.json
20
railway.json
@@ -1,18 +1,10 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://railway.app/railway.schema.json",
|
"build": "npm install && npm run build",
|
||||||
"build": {
|
"start": "npm start",
|
||||||
"builder": "NIXPACKS"
|
"service": {
|
||||||
},
|
"port": 8080,
|
||||||
"services": [
|
"healthcheck": {
|
||||||
{
|
"path": "/api/health"
|
||||||
"name": "docs-site",
|
|
||||||
"buildCommand": "npm ci && npm run build",
|
|
||||||
"startCommand": "npm run start",
|
|
||||||
"healthcheckPath": "/health",
|
|
||||||
"env": {
|
|
||||||
"NODE_ENV": "production",
|
|
||||||
"PUBLIC_DOCS_URL": "https://docs.blackroad.dev"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
const { execSync } = require('node:child_process');
|
const { execSync } = require('node:child_process');
|
||||||
const { writeFileSync, mkdirSync, readFileSync } = require('node:fs');
|
const { writeFileSync, mkdirSync, readFileSync } = require('node:fs');
|
||||||
const { join } = require('node:path');
|
const { join } = require('node:path');
|
||||||
|
const { SERVICE_ID, SERVICE_NAME, SERVICE_BASE_URL, OS_ROOT } = require('../src/config/serviceConfig');
|
||||||
const docsConfig = require('../src/config/docsConfig');
|
const docsConfig = require('../src/config/docsConfig');
|
||||||
|
|
||||||
const BUILD_TIME = process.env.RAILWAY_BUILD_TIME || process.env.BUILD_TIME || new Date().toISOString();
|
const BUILD_TIME = process.env.RAILWAY_BUILD_TIME || process.env.BUILD_TIME || new Date().toISOString();
|
||||||
|
|
||||||
const SERVICE_NAME = docsConfig.serviceName;
|
|
||||||
|
|
||||||
function getCommitSha() {
|
function getCommitSha() {
|
||||||
if (process.env.RAILWAY_GIT_COMMIT_SHA) {
|
if (process.env.RAILWAY_GIT_COMMIT_SHA) {
|
||||||
return process.env.RAILWAY_GIT_COMMIT_SHA;
|
return process.env.RAILWAY_GIT_COMMIT_SHA;
|
||||||
@@ -34,9 +33,19 @@ function buildMeta() {
|
|||||||
const version = getVersion();
|
const version = getVersion();
|
||||||
|
|
||||||
const healthPayload = {
|
const healthPayload = {
|
||||||
status: 'ok',
|
ok: true,
|
||||||
timestamp,
|
service: SERVICE_ID,
|
||||||
environment: docsConfig.env,
|
ts: timestamp,
|
||||||
|
baseUrl: SERVICE_BASE_URL,
|
||||||
|
osRoot: OS_ROOT,
|
||||||
|
};
|
||||||
|
|
||||||
|
const infoPayload = {
|
||||||
|
name: SERVICE_NAME,
|
||||||
|
id: SERVICE_ID,
|
||||||
|
baseUrl: SERVICE_BASE_URL,
|
||||||
|
osRoot: OS_ROOT,
|
||||||
|
ts: timestamp,
|
||||||
};
|
};
|
||||||
|
|
||||||
const versionPayload = {
|
const versionPayload = {
|
||||||
@@ -48,17 +57,36 @@ function buildMeta() {
|
|||||||
docsUrl: docsConfig.publicDocsUrl,
|
docsUrl: docsConfig.publicDocsUrl,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
const debugEnvPayload = {
|
||||||
|
env: docsConfig.env,
|
||||||
|
NODE_ENV: process.env.NODE_ENV || 'development',
|
||||||
|
SERVICE_BASE_URL,
|
||||||
|
OS_ROOT,
|
||||||
|
PUBLIC_DOCS_URL: process.env.PUBLIC_DOCS_URL || null,
|
||||||
|
};
|
||||||
|
|
||||||
const staticDir = join(process.cwd(), 'static');
|
const staticDir = join(process.cwd(), 'static');
|
||||||
mkdirSync(staticDir, { recursive: true });
|
mkdirSync(staticDir, { recursive: true });
|
||||||
|
|
||||||
writeFileSync(join(staticDir, 'health.json'), JSON.stringify(healthPayload, null, 2));
|
writeFileSync(join(staticDir, 'health.json'), JSON.stringify(healthPayload, null, 2));
|
||||||
writeFileSync(join(staticDir, 'version.json'), JSON.stringify(versionPayload, null, 2));
|
writeFileSync(join(staticDir, 'version.json'), JSON.stringify(versionPayload, null, 2));
|
||||||
|
writeFileSync(join(staticDir, 'info.json'), JSON.stringify(infoPayload, null, 2));
|
||||||
|
writeFileSync(join(staticDir, 'debug-env.json'), JSON.stringify(debugEnvPayload, null, 2));
|
||||||
|
|
||||||
mkdirSync(join(staticDir, 'health'), { recursive: true });
|
const apiDir = join(staticDir, 'api');
|
||||||
mkdirSync(join(staticDir, 'version'), { recursive: true });
|
mkdirSync(apiDir, { recursive: true });
|
||||||
|
|
||||||
writeFileSync(join(staticDir, 'health', 'index.json'), JSON.stringify(healthPayload, null, 2));
|
const healthDir = join(apiDir, 'health');
|
||||||
writeFileSync(join(staticDir, 'version', 'index.json'), JSON.stringify(versionPayload, null, 2));
|
const infoDir = join(apiDir, 'info');
|
||||||
|
const versionDir = join(apiDir, 'version');
|
||||||
|
const debugEnvDir = join(apiDir, 'debug-env');
|
||||||
|
|
||||||
|
[healthDir, infoDir, versionDir, debugEnvDir].forEach((dir) => mkdirSync(dir, { recursive: true }));
|
||||||
|
|
||||||
|
writeFileSync(join(healthDir, 'index.json'), JSON.stringify(healthPayload, null, 2));
|
||||||
|
writeFileSync(join(infoDir, 'index.json'), JSON.stringify(infoPayload, null, 2));
|
||||||
|
writeFileSync(join(versionDir, 'index.json'), JSON.stringify(versionPayload, null, 2));
|
||||||
|
writeFileSync(join(debugEnvDir, 'index.json'), JSON.stringify(debugEnvPayload, null, 2));
|
||||||
}
|
}
|
||||||
|
|
||||||
buildMeta();
|
buildMeta();
|
||||||
|
|||||||
20
src/config/serviceConfig.js
Normal file
20
src/config/serviceConfig.js
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
const SERVICE_ID = 'docs';
|
||||||
|
const SERVICE_NAME = 'BlackRoad OS – Docs';
|
||||||
|
const SERVICE_BASE_URL = process.env.SERVICE_BASE_URL || 'https://docs.blackroad.systems';
|
||||||
|
const OS_ROOT = process.env.OS_ROOT || 'https://blackroad.systems';
|
||||||
|
|
||||||
|
const serviceConfig = {
|
||||||
|
SERVICE_ID,
|
||||||
|
SERVICE_NAME,
|
||||||
|
SERVICE_BASE_URL,
|
||||||
|
OS_ROOT,
|
||||||
|
};
|
||||||
|
|
||||||
|
module.exports = {
|
||||||
|
SERVICE_ID,
|
||||||
|
SERVICE_NAME,
|
||||||
|
SERVICE_BASE_URL,
|
||||||
|
OS_ROOT,
|
||||||
|
serviceConfig,
|
||||||
|
default: serviceConfig,
|
||||||
|
};
|
||||||
35
src/pages/architecture.jsx
Normal file
35
src/pages/architecture.jsx
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
import Layout from '@theme/Layout';
|
||||||
|
import React from 'react';
|
||||||
|
|
||||||
|
export default function Architecture() {
|
||||||
|
return (
|
||||||
|
<Layout title="Architecture" description="High-level architecture for BlackRoad OS">
|
||||||
|
<main className="container margin-vert--lg">
|
||||||
|
<header className="margin-bottom--lg">
|
||||||
|
<h1>Architecture</h1>
|
||||||
|
<p className="subtitle">How users, frontends, and backends flow together in BlackRoad OS.</p>
|
||||||
|
</header>
|
||||||
|
|
||||||
|
<section className="margin-bottom--lg">
|
||||||
|
<h2>System flow</h2>
|
||||||
|
<p>The following text diagram highlights the primary request paths:</p>
|
||||||
|
<pre>
|
||||||
|
Users & Agents → Web & Console
|
||||||
|
Web → Public API → Core
|
||||||
|
Console → API → Core + Operator
|
||||||
|
Operator → async tasks, queues, workflows
|
||||||
|
</pre>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<section className="margin-bottom--lg">
|
||||||
|
<h2>Platform layers</h2>
|
||||||
|
<ul>
|
||||||
|
<li><strong>Frontends</strong>: public web experience, Prism Console, and this docs site.</li>
|
||||||
|
<li><strong>Backends</strong>: Core for the ledger and main business logic; API for the external gateway; Operator for asynchronous orchestration.</li>
|
||||||
|
<li><strong>Shared infrastructure</strong>: Railway hosts the services, Cloudflare fronts the domains, and <code>blackroad.systems</code> anchors the URLs.</li>
|
||||||
|
</ul>
|
||||||
|
</section>
|
||||||
|
</main>
|
||||||
|
</Layout>
|
||||||
|
);
|
||||||
|
}
|
||||||
55
src/pages/getting-started.jsx
Normal file
55
src/pages/getting-started.jsx
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
import Layout from '@theme/Layout';
|
||||||
|
import Link from '@docusaurus/Link';
|
||||||
|
import React from 'react';
|
||||||
|
import serviceConfig from '../config/serviceConfig';
|
||||||
|
|
||||||
|
export default function GettingStarted() {
|
||||||
|
return (
|
||||||
|
<Layout title="Getting Started" description="Start using the BlackRoad Operating System">
|
||||||
|
<main className="container margin-vert--lg">
|
||||||
|
<header className="margin-bottom--lg">
|
||||||
|
<h1>Getting Started</h1>
|
||||||
|
<p className="subtitle">Understand the BlackRoad Operating System and take your first steps.</p>
|
||||||
|
</header>
|
||||||
|
|
||||||
|
<section className="margin-bottom--lg">
|
||||||
|
<h2>What is BlackRoad OS?</h2>
|
||||||
|
<p>
|
||||||
|
BlackRoad OS is the platform layer for orchestrating digital logistics and operational workflows. It brings together
|
||||||
|
public-facing frontends, operator consoles, and backend services into a single, reliable surface.
|
||||||
|
</p>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<section className="margin-bottom--lg">
|
||||||
|
<h2>Core services</h2>
|
||||||
|
<ul>
|
||||||
|
<li><strong>core</strong> – Ledger and core API that acts as the system of record.</li>
|
||||||
|
<li><strong>api</strong> – Public gateway that fronts the core for external access.</li>
|
||||||
|
<li><strong>operator</strong> – Workers, queues, and background orchestration.</li>
|
||||||
|
<li><strong>console</strong> – Prism Console for operators and administrators.</li>
|
||||||
|
<li><strong>web</strong> – Public-facing site for users and partners.</li>
|
||||||
|
<li><strong>docs</strong> – This documentation site that explains how everything connects.</li>
|
||||||
|
</ul>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<section className="margin-bottom--lg">
|
||||||
|
<h2>Environments</h2>
|
||||||
|
<p>
|
||||||
|
Services are hosted on Railway and published under the <code>blackroad.systems</code> domain family. Use HTTPS endpoints
|
||||||
|
in each environment for predictable connectivity.
|
||||||
|
</p>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<section className="margin-bottom--lg">
|
||||||
|
<h2>First steps checklist</h2>
|
||||||
|
<ol>
|
||||||
|
<li>Visit the public site: <Link to="https://blackroad.systems">blackroad.systems</Link>.</li>
|
||||||
|
<li>Open the console: <Link to="https://console.blackroad.systems">console.blackroad.systems</Link>.</li>
|
||||||
|
<li>Hit the API probe: <Link to="https://api.blackroad.systems/health">api.blackroad.systems/health</Link>.</li>
|
||||||
|
<li>Stay in the docs: <Link to={serviceConfig.SERVICE_BASE_URL}>Docs homepage</Link>.</li>
|
||||||
|
</ol>
|
||||||
|
</section>
|
||||||
|
</main>
|
||||||
|
</Layout>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -1,57 +1,75 @@
|
|||||||
import Link from '@docusaurus/Link';
|
import Link from '@docusaurus/Link';
|
||||||
import Layout from '@theme/Layout';
|
import Layout from '@theme/Layout';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import docsConfig from '../config/docsConfig';
|
import serviceConfig from '../config/serviceConfig';
|
||||||
|
|
||||||
|
const quickLinks = [
|
||||||
|
{ href: '/getting-started', label: 'Getting Started' },
|
||||||
|
{ href: '/architecture', label: 'Architecture' },
|
||||||
|
{ href: '/services', label: 'Services' },
|
||||||
|
];
|
||||||
|
|
||||||
export default function Home() {
|
export default function Home() {
|
||||||
return (
|
return (
|
||||||
<Layout title="BlackRoad OS" description="Unified documentation for BlackRoad OS">
|
<Layout title="BlackRoad OS – Documentation" description="Architecture, services, and integration guides for BlackRoad OS.">
|
||||||
<header className="hero hero--primary homepage-hero">
|
<header className="hero hero--primary homepage-hero">
|
||||||
<div className="container">
|
<div className="container">
|
||||||
<h1 className="hero__title">BlackRoad OS Handbook</h1>
|
<h1 className="hero__title">BlackRoad OS – Documentation</h1>
|
||||||
<p className="hero__subtitle">One place for platform architecture, operational playbooks, and onboarding.</p>
|
<p className="hero__subtitle">Architecture, services, and integration guides for BlackRoad OS.</p>
|
||||||
<div className="buttons">
|
<div className="buttons">
|
||||||
<Link className="button button--secondary button--lg" to="/intro/overview">
|
{quickLinks.map((link) => (
|
||||||
Start with the overview
|
<Link key={link.href} className="button button--secondary button--lg" to={link.href}>
|
||||||
</Link>
|
{link.label}
|
||||||
<Link className="button button--outline button--lg" to="/infra/environments">
|
|
||||||
Environment reference
|
|
||||||
</Link>
|
</Link>
|
||||||
|
))}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
<main className="container margin-vert--lg">
|
<main className="container margin-vert--lg">
|
||||||
<div className="callout-grid">
|
<section className="row">
|
||||||
<div className="callout-card">
|
<div className="col col--6">
|
||||||
<h3>Systems</h3>
|
<h2>What you will find here</h2>
|
||||||
<p className="card-subtitle">Core, Web UI, Prism Console, Agents</p>
|
<ul>
|
||||||
<p>Discover how each surface interacts, which env vars matter, and where to extend the platform.</p>
|
<li>How the BlackRoad Operating System fits together across frontends, APIs, and workers.</li>
|
||||||
<Link to="/core/overview">Explore system docs →</Link>
|
<li>Environment and deployment notes for Railway and the <code>blackroad.systems</code> domain family.</li>
|
||||||
</div>
|
<li>Service-by-service responsibilities with links to deeper docs in each section.</li>
|
||||||
<div className="callout-card">
|
</ul>
|
||||||
<h3>Infra & Deploy</h3>
|
|
||||||
<p className="card-subtitle">Railway + Cloudflare</p>
|
|
||||||
<p>Deployment flows, domains, CI/CD, and environment mappings with health/version probes baked in.</p>
|
|
||||||
<Link to="/infra/railway">Read infra playbooks →</Link>
|
|
||||||
</div>
|
|
||||||
<div className="callout-card">
|
|
||||||
<h3>Onboarding</h3>
|
|
||||||
<p className="card-subtitle">Developers, Operators, Partners</p>
|
|
||||||
<p>Get local setups running fast with repo guides, branching strategy, and shared style rules.</p>
|
|
||||||
<Link to="/onboarding/developer-setup">Onboard now →</Link>
|
|
||||||
</div>
|
</div>
|
||||||
|
<div className="col col--6">
|
||||||
|
<h2>Quick navigation</h2>
|
||||||
|
<ul>
|
||||||
|
{quickLinks.map((link) => (
|
||||||
|
<li key={link.href}>
|
||||||
|
<Link to={link.href}>{link.label}</Link>
|
||||||
|
</li>
|
||||||
|
))}
|
||||||
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
<div className="margin-top--lg">
|
<section className="margin-top--lg">
|
||||||
<p className="text--center">
|
<h2>Service metadata</h2>
|
||||||
Docs served from <strong>{docsConfig.publicDocsUrl}</strong>{' '}
|
<p className="margin-bottom--sm">Values pulled from the shared service configuration.</p>
|
||||||
{docsConfig.coreApiUrl && <>| Core API: {docsConfig.coreApiUrl} </>}
|
<div className="card">
|
||||||
{docsConfig.webAppUrl && <>| Web App: {docsConfig.webAppUrl} </>}
|
<div className="card__body">
|
||||||
{docsConfig.consoleUrl && <>| Console: {docsConfig.consoleUrl} </>}
|
<ul>
|
||||||
{docsConfig.agentsApiUrl && <>| Agents API: {docsConfig.agentsApiUrl}</>}
|
<li>
|
||||||
</p>
|
<strong>Service ID:</strong> {serviceConfig.SERVICE_ID}
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<strong>Service Name:</strong> {serviceConfig.SERVICE_NAME}
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<strong>Service Base URL:</strong> {serviceConfig.SERVICE_BASE_URL}
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<strong>OS Root:</strong> {serviceConfig.OS_ROOT}
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
</main>
|
</main>
|
||||||
</Layout>
|
</Layout>
|
||||||
);
|
);
|
||||||
|
|||||||
78
src/pages/services.jsx
Normal file
78
src/pages/services.jsx
Normal file
@@ -0,0 +1,78 @@
|
|||||||
|
import Layout from '@theme/Layout';
|
||||||
|
import React from 'react';
|
||||||
|
import serviceConfig from '../config/serviceConfig';
|
||||||
|
|
||||||
|
const services = [
|
||||||
|
{
|
||||||
|
name: 'BlackRoad OS Core',
|
||||||
|
id: 'core',
|
||||||
|
baseUrl: 'https://core.blackroad.systems',
|
||||||
|
role: 'Ledger and primary business logic that anchors the OS.',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Public API Gateway',
|
||||||
|
id: 'api',
|
||||||
|
baseUrl: 'https://api.blackroad.systems',
|
||||||
|
role: 'Externally facing entry point that fronts the core.',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Operator',
|
||||||
|
id: 'operator',
|
||||||
|
baseUrl: 'https://operator.blackroad.systems',
|
||||||
|
role: 'Workers and background jobs that coordinate async workflows.',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Prism Console',
|
||||||
|
id: 'console',
|
||||||
|
baseUrl: 'https://console.blackroad.systems',
|
||||||
|
role: 'Operational console for teams to manage the platform.',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Web',
|
||||||
|
id: 'web',
|
||||||
|
baseUrl: 'https://blackroad.systems',
|
||||||
|
role: 'Public web experience for users and partners.',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Docs',
|
||||||
|
id: serviceConfig.SERVICE_ID,
|
||||||
|
baseUrl: serviceConfig.SERVICE_BASE_URL,
|
||||||
|
role: 'Documentation portal describing architecture, services, and integration guides.',
|
||||||
|
},
|
||||||
|
];
|
||||||
|
|
||||||
|
export default function Services() {
|
||||||
|
return (
|
||||||
|
<Layout title="Services" description="Service catalog for BlackRoad OS">
|
||||||
|
<main className="container margin-vert--lg">
|
||||||
|
<header className="margin-bottom--lg">
|
||||||
|
<h1>Services</h1>
|
||||||
|
<p className="subtitle">Overview of the platform surfaces and their responsibilities.</p>
|
||||||
|
</header>
|
||||||
|
|
||||||
|
<div className="table-container">
|
||||||
|
<table className="table">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th>Name</th>
|
||||||
|
<th>ID</th>
|
||||||
|
<th>Base URL</th>
|
||||||
|
<th>Role</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
{services.map((service) => (
|
||||||
|
<tr key={service.id}>
|
||||||
|
<td>{service.name}</td>
|
||||||
|
<td>{service.id}</td>
|
||||||
|
<td>{service.baseUrl}</td>
|
||||||
|
<td>{service.role}</td>
|
||||||
|
</tr>
|
||||||
|
))}
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</main>
|
||||||
|
</Layout>
|
||||||
|
);
|
||||||
|
}
|
||||||
7
static/api/debug-env/index.json
Normal file
7
static/api/debug-env/index.json
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"env": "development",
|
||||||
|
"NODE_ENV": "development",
|
||||||
|
"SERVICE_BASE_URL": "https://docs.blackroad.systems",
|
||||||
|
"OS_ROOT": "https://blackroad.systems",
|
||||||
|
"PUBLIC_DOCS_URL": null
|
||||||
|
}
|
||||||
7
static/api/health/index.json
Normal file
7
static/api/health/index.json
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"ok": true,
|
||||||
|
"service": "docs",
|
||||||
|
"ts": "2025-11-21T02:26:02.384Z",
|
||||||
|
"baseUrl": "https://docs.blackroad.systems",
|
||||||
|
"osRoot": "https://blackroad.systems"
|
||||||
|
}
|
||||||
7
static/api/info/index.json
Normal file
7
static/api/info/index.json
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"name": "BlackRoad OS – Docs",
|
||||||
|
"id": "docs",
|
||||||
|
"baseUrl": "https://docs.blackroad.systems",
|
||||||
|
"osRoot": "https://blackroad.systems",
|
||||||
|
"ts": "2025-11-21T02:26:02.384Z"
|
||||||
|
}
|
||||||
8
static/api/version/index.json
Normal file
8
static/api/version/index.json
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
{
|
||||||
|
"service": "BlackRoad OS – Docs",
|
||||||
|
"appVersion": "0.1.0",
|
||||||
|
"commit": "e10685a5cc1efc3f6282a7ab949c4f1e1cc72213",
|
||||||
|
"buildTime": "2025-11-21T02:26:02.383Z",
|
||||||
|
"environment": "development",
|
||||||
|
"docsUrl": "http://localhost:3000"
|
||||||
|
}
|
||||||
7
static/debug-env.json
Normal file
7
static/debug-env.json
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"env": "development",
|
||||||
|
"NODE_ENV": "development",
|
||||||
|
"SERVICE_BASE_URL": "https://docs.blackroad.systems",
|
||||||
|
"OS_ROOT": "https://blackroad.systems",
|
||||||
|
"PUBLIC_DOCS_URL": null
|
||||||
|
}
|
||||||
@@ -1,5 +1,7 @@
|
|||||||
{
|
{
|
||||||
"status": "ok",
|
"ok": true,
|
||||||
"timestamp": "2025-11-20T18:35:36.292Z",
|
"service": "docs",
|
||||||
"environment": "production"
|
"ts": "2025-11-21T02:26:02.384Z",
|
||||||
|
"baseUrl": "https://docs.blackroad.systems",
|
||||||
|
"osRoot": "https://blackroad.systems"
|
||||||
}
|
}
|
||||||
7
static/info.json
Normal file
7
static/info.json
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"name": "BlackRoad OS – Docs",
|
||||||
|
"id": "docs",
|
||||||
|
"baseUrl": "https://docs.blackroad.systems",
|
||||||
|
"osRoot": "https://blackroad.systems",
|
||||||
|
"ts": "2025-11-21T02:26:02.384Z"
|
||||||
|
}
|
||||||
@@ -1,8 +1,8 @@
|
|||||||
{
|
{
|
||||||
"service": "docs-site",
|
"service": "BlackRoad OS – Docs",
|
||||||
"appVersion": "0.1.0",
|
"appVersion": "0.1.0",
|
||||||
"commit": "76f3de887875c785944a97d81e17b199b3b3b5e7",
|
"commit": "e10685a5cc1efc3f6282a7ab949c4f1e1cc72213",
|
||||||
"buildTime": "2025-11-20T18:35:36.292Z",
|
"buildTime": "2025-11-21T02:26:02.383Z",
|
||||||
"environment": "production",
|
"environment": "development",
|
||||||
"docsUrl": "http://localhost:3000"
|
"docsUrl": "http://localhost:3000"
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user