Public site
The landing page, the pages about Werker and the blog are a separate
app, apps/site. It is deployed at werker.cloud, with the app
(apps/app) at app.werker.cloud, as two Coolify applications
(Coolify).
Why two apps
- The site has no database or sign-in, and its server only runs the waiting list. Its policy in
tools/checks/policy.tsallows only@werkerai/uiand the pure@werkerai/rules. - The site builds without the app.
- A self-hosted install gets the app only. Its
/redirects to the dashboard or to sign-in (apps/app/src/routes/+server.ts).
Deploying it
A second Coolify application from the same repository, beside the app. Its addresses and sender are in apps/site/src/lib/site.ts.
| Setting | Value |
|---|---|
| Site type | Dynamic (a web application) |
| Build pack | Railpack, base directory / |
| Build command | pnpm --filter @werkerai/site build |
| Start command | pnpm --filter @werkerai/site start |
| Port | 3000 |
| Publish directory | none; Coolify shows / |
- Environment: the four
RESEND_*variables of the waiting list, andWERKER_SITE_ORIGINon the app for page views. - A push to
mainredeploys both applications.
What is shared: packages/ui
The theme tokens, the logo and the shadcn-svelte primitives are in packages/ui (opens in a new tab). Each app
compiles them from source in its own build.
How the site is built
- SvelteKit with
@sveltejs/adapter-node; every route is prerendered (apps/site/src/routes/+layout.ts).pnpm buildwritesapps/site/build/. pnpm dev:siteserves it on port 5232.- Pages and posts are markdown in
apps/site/src/content/pages/andapps/site/src/content/blog/, compiled by mdsvex 1.1.0 (a Vite plugin). Code fences are highlighted with twinkleplop at build time (@twinkleplop/theme-night-owl). - Frontmatter is checked at build (
apps/site/src/lib/content.ts):title,description(200 characters at most),updated, andpublishedfor a post. A missing or bad field fails the build. - The order of pages, in menus and in
llms.txt, ispage_orderin the same file. Short menu names are inapps/site/src/lib/messaging/chrome.ts.
The docs section
/docs is every doc, written in apps/site/src/content/docs/: pages
for people using Werker, and engineering/ for working on its code
(.agents/skills/docs/SKILL.md). Root docs/ holds one generated
file, glossary.md, written by pnpm docs:glossary (apps/site/src/lib/server/glossary.ts); a test fails when it is
stale.
- Layout: the docs have their own
(
apps/site/src/routes/docs/+layout.svelte). Every other page is inapps/site/src/routes/(site)/. - Groups and order:
apps/site/src/lib/docs/groups.ts. A doc it leaves out fails a test./docsredirects to Getting started. - Frontmatter: as for a page.
- Moved pages:
apps/site/src/lib/moved.tslists the old addresses, which the server redirects (src/hooks.server.ts). - Links: between docs they become pages; anything else in the
repository opens on GitHub (
apps/site/src/lib/docs/links.ts). A link to a missing doc or heading fails the build. - Writing: the rule on
{,},<and>below applies here. - Search: the browser fetches every section once, from
/docs/search.json, and ranks them itself (apps/site/src/lib/docs/search.ts)./docs/search?q=lists more. A result opens with the words marked from?find=(apps/site/src/lib/docs/highlight.ts). - Links to other sites open in a new tab
(
apps/site/src/lib/components/document-link.svelte), in pages and posts too. - Link graph:
/docs/graph(apps/site/src/lib/components/docs/graph.svelte). - Credit: the sidebar credits wiki0 (opens in a new tab) (
apps/site/src/lib/components/docs/wiki0-credit.svelte).
Adding a page or a post
- Add
apps/site/src/content/pages/<slug>.mdorapps/site/src/content/blog/<slug>.mdwith the frontmatter above. - For a page, add its slug to
page_order. - Outside code spans and fences, do not write
{,},<or>: mdsvex reads them as Svelte. A value containing:in the frontmatter must be quoted.
What is written for programs
Each is built from the same lists as the pages
(apps/site/src/lib/server/machine-files.ts).
| Address | What it is |
|---|---|
/<slug>.md | The page as markdown, with its title and address on top |
/blog/<slug>.md | The post as markdown |
/docs/<slug>.md | The doc as markdown |
/llms.txt | An index: what Werker is, then a link to each page's and doc's markdown |
/llms-full.txt | Every page, doc and post in one markdown file |
/sitemap.xml | Every page, doc and post with the date it was updated |
/robots.txt | Allows every crawler and names the sitemap |
/blog/rss.xml | The blog as RSS 2.0 |
Head tags and share cards
- Head tags come from svead (opens in a new tab) 0.2.0, in one component (
apps/site/src/lib/components/seo.svelte): the title, description, canonical link, Open Graph and Twitter tags. The same component adds a link to the page's markdown. - JSON-LD is written by svead's
SchemaOrgfrom typed nodes (apps/site/src/lib/structured-data.ts):WebSiteandSoftwareApplicationon/,TechArticleon a page,BlogPostingon a post, andFAQPageon/faq, read from its##headings (apps/site/src/lib/server/faq.ts). - Every page, post and doc has its own share card, a 1200 by 630 PNG
at
/api/og-image/<slug>.png(blog-<slug>for a post,docs-<slug>for a doc,sitefor/). Nothing is drawn by hand: the card is an SVG built from the page's title and description and rendered with Resvg (WASM) while the site is built (apps/site/src/lib/og/cards.ts,apps/site/src/lib/server/og/render.ts). - The cards are set in Inter, from two TTF files in
apps/site/src/lib/server/og/fonts/(SIL Open Font License,OFL.txtbeside them).
Pages
| Page | Answers | Drafted from |
|---|---|---|
/ | What Werker is | apps/site/src/routes/(site)/+page.svelte |
/how-it-works | Describe, generate, run, result; factories | agents, workflows and factories |
/security | Sandboxes, network, keys, workspaces | sandboxes, workspaces |
/pricing | The three offerings; no prices | hosting plan (opens in a new tab) |
/status | Each built thing and how far it was tested | status epic (opens in a new tab) |
/fit | Who it suits today and who should wait | status epic (opens in a new tab) |
/faq | Short answers | The pages above |
Waiting list
The form on the landing page and the dialog a link opens there use
remote functions (apps/site/src/lib/waiting-list.remote.ts), and the
site's server calls Resend itself: the app has no part in it.
- Joining emails a link to the landing page; a button in its dialog adds the address to a Resend segment, one per answer. Opening the link does not.
- The site keeps no list. What was asked for is signed into the link, in the fragment, and lasts 7 days.
- Resend: the sender is at a domain verified in Resend
(
email_frominapps/site/src/lib/site.ts). Environment:RESEND_API_KEY(sending),RESEND_CONTACTS_KEY(contacts), and the segment IDsRESEND_USE_SEGMENTandRESEND_HOST_SEGMENT. Without all four the form says sign-ups are closed. - One address is emailed at most every 10 minutes for each answer, and 100 emails an hour in all, counted in the process: a restart forgets.
Visitor analytics
The site's page views are recorded by the app and shown in Admin →
Analytics with the app's own
(visitor analytics). Set WERKER_SITE_ORIGIN=https://werker.cloud on the app. The site posts
to app_url in apps/site/src/lib/site.ts; it does not post in
development.