Web UI

Every node serves a page that shows the cluster and changes it: what is running where, a form for every kind (drawn from its schema, your own kinds included), the YAML beside it, status, history with rollback, and output. An apply or a rollback shows its diff first; a delete asks.

The web UI asking before it applies: 'Apply 1 change?' over the diff of Workload/default/web, replicas 3 struck out in red and replicas 5 added in blue, with Cancel and Apply

The web UI at a phone's width: three nodes as stops on lines, mail with 0 of 2 replicas ready and web with 3 of 3, the list of Workloads under them, and the form of the one that is open

On a node, as its admin:

kith ui                 # prints http://127.0.0.1:PORT/SECRET/ui/ ; open it
kith ui --port 7000     # a port of your choosing

From your own machine, through SSH (kith ui --port 7000 on the node, then):

ssh -L 7000:127.0.0.1:7000 node    # and open the printed address here

The address is the key: kith ui passes on only requests under that secret path, asked for under this machine's own name, by its own page, and stops when you stop it. Keep it to yourself.

As an Identity, a browser can also open https://kith:7443/ui/ on a node's TLS port and act as that Identity, with what its Roles allow and no more. It needs the Identity's certificate (openssl pkcs12 -export -in alice.crt -inkey alice.key -out alice.p12, imported into the browser), ca.crt trusted, and the name kith pointing at a node (a line in /etc/hosts).

  • The page is a few files inside kithd, open to all: everything it asks is not. No framework, nothing fetched from elsewhere (its content policy forbids it): it works with no internet.
  • It asks kithd as you: the same API, rules and audit log as kith and curl; POST /v1/diff is the dry run it shows. A field the form cannot draw (a free-form object, oneOf) is a JSON box; the YAML tab edits anything.
  • A Workload, Job or NodeWorkload has a Terminal tab: a shell in one of its replicas, over a WebSocket to GET /v1/exec/NAMESPACE/POD (the pod is named as kubectl names it). It is a line at a time, with no tty: no editor, no prompt, no colours. It takes the exec right on the owning Workload or Job (and on Node for a NodeWorkload), asked again on the node that runs the replica, like kubectl exec (SECURITY.md); and it opens only from the page's own origin, never from another site's page.
  • A Workload or Volume has a Files tab: the Volume's directories (GET /v1/volumes/NAMESPACE/NAME/ls?path=DIR), a file downloaded (GET …/files?path=FILE) and a file uploaded into the directory in view (up to 64 MiB; a larger one goes with kith volume cp). It takes apply on Volume and on Workload, as kith volume put and get do, and never follows a link out of the Volume: a link is shown as one, not opened.
  • Usage graphs have their data in GET /v1/metrics?range=15m|1h|6h|24h (default 1h): each node's CPU (0 to 1), memory, state disk, disk read and write, network receive and send (bytes per second, every interface but lo) and 1-minute load, and each Workload's CPU (cores) and memory, as arrays oldest first (null where nothing was sampled), the last point at end and step seconds apart. It takes the right to list Nodes. A node that does not answer in 3 seconds, or has no address yet, is "missing": true and the rest comes back. A Workload's series show only for the namespaces you may list or get Workloads in. The page itself that draws them is not here yet.
  • Not yet: logging in without a certificate (OIDC), secrets hidden until asked for.