From 7402d2e97a8128124faa23e6b6f8b15a3ccee3a5 Mon Sep 17 00:00:00 2001 From: ai-bot Date: Sun, 11 Oct 2026 10:44:39 +0000 Subject: [PATCH] Add the VardKey web interface definition --- startos/interfaces.ts | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 startos/interfaces.ts diff --git a/startos/interfaces.ts b/startos/interfaces.ts new file mode 100644 index 0000000..f139b37 --- /dev/null +++ b/startos/interfaces.ts @@ -0,0 +1,27 @@ +import { i18n } from './i18n' +import { sdk } from './sdk' +import { uiPort } from './utils' + +export const setInterfaces = sdk.setupInterfaces(async ({ effects }) => { + const uiMulti = sdk.MultiHost.of(effects, 'ui') + const uiMultiOrigin = await uiMulti.bindPort(uiPort, { + protocol: 'http', + preferredExternalPort: 80, + }) + + const ui = sdk.createInterface(effects, { + name: i18n('Web UI'), + id: 'ui', + description: i18n('The web interface of VardKey'), + type: 'ui', + masked: false, + schemeOverride: null, + username: null, + path: '', + query: {}, + }) + + const uiReceipt = await uiMultiOrigin.export([ui]) + + return [uiReceipt] +})