@camstack/system 1.2.437 → 1.2.439
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/addon-runner.js +64 -12
- package/dist/addon-runner.mjs +65 -13
- package/dist/{agent-https-BZIwS4xF.js → agent-https-DlpTMDqA.js} +252 -22
- package/dist/{agent-https-BPfHrI4c.mjs → agent-https-U0d4uvn2.mjs} +211 -23
- package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +1 -1
- package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +1 -1
- package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +1 -1
- package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +1 -1
- package/dist/builtins/alerts/alerts.addon.js +7 -1
- package/dist/builtins/alerts/alerts.addon.mjs +7 -1
- package/dist/builtins/autotrack/index.js +1 -1
- package/dist/builtins/autotrack/index.mjs +1 -1
- package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +2 -2
- package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +2 -2
- package/dist/builtins/calendars/calendars.addon.js +1 -1
- package/dist/builtins/calendars/calendars.addon.mjs +1 -1
- package/dist/builtins/camera-grid/index.js +9 -1
- package/dist/builtins/camera-grid/index.mjs +9 -1
- package/dist/builtins/composer/composer.addon.js +2 -2
- package/dist/builtins/composer/composer.addon.mjs +2 -2
- package/dist/builtins/console-logging/index.js +12 -5
- package/dist/builtins/console-logging/index.mjs +12 -5
- package/dist/builtins/core-blocks/core-blocks.addon.js +2 -2
- package/dist/builtins/core-blocks/core-blocks.addon.mjs +2 -2
- package/dist/builtins/device-manager/device-manager.addon.d.ts +5 -0
- package/dist/builtins/device-manager/device-manager.addon.js +717 -28
- package/dist/builtins/device-manager/device-manager.addon.mjs +717 -28
- package/dist/builtins/device-manager/device-meta-types.d.ts +4 -0
- package/dist/builtins/device-manager/device-provider-context.d.ts +9 -0
- package/dist/builtins/device-manager/device-removal-hooks.d.ts +103 -0
- package/dist/builtins/device-manager/device-row-store.d.ts +1 -0
- package/dist/builtins/device-manager/device-tombstone-store.d.ts +68 -0
- package/dist/builtins/device-manager/removal-cleanup.d.ts +50 -0
- package/dist/builtins/hub-forwarder/index.js +1 -1
- package/dist/builtins/hub-forwarder/index.mjs +1 -1
- package/dist/builtins/keychain/index.js +37 -4
- package/dist/builtins/keychain/index.mjs +37 -4
- package/dist/builtins/keychain/keychain-service.d.ts +14 -0
- package/dist/builtins/keychain/keychain-store.d.ts +1 -1
- package/dist/builtins/liveness-monitor/liveness-monitor.addon.js +1 -1
- package/dist/builtins/liveness-monitor/liveness-monitor.addon.mjs +1 -1
- package/dist/builtins/local-auth/local-auth.addon.js +12 -12
- package/dist/builtins/local-auth/local-auth.addon.mjs +12 -12
- package/dist/builtins/local-network/local-network.addon.js +16 -2
- package/dist/builtins/local-network/local-network.addon.mjs +16 -2
- package/dist/builtins/loki-logging/index.js +28 -5
- package/dist/builtins/loki-logging/index.mjs +28 -5
- package/dist/builtins/native-metrics/native-metrics.addon.js +11 -1
- package/dist/builtins/native-metrics/native-metrics.addon.mjs +11 -1
- package/dist/builtins/platform-probe/index.js +1 -1
- package/dist/builtins/platform-probe/index.mjs +1 -1
- package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +1 -1
- package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +1 -1
- package/dist/builtins/snapshot/index.js +11 -1
- package/dist/builtins/snapshot/index.mjs +11 -1
- package/dist/builtins/sqlite-storage/filesystem-storage.addon.js +4 -1
- package/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +4 -1
- package/dist/builtins/sqlite-storage/index.js +1 -1
- package/dist/builtins/sqlite-storage/index.mjs +1 -1
- package/dist/builtins/sqlite-storage/sqlite-settings.addon.js +3 -3
- package/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +3 -3
- package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +1 -1
- package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +1 -1
- package/dist/builtins/system-config/system-config.addon.js +22 -4
- package/dist/builtins/system-config/system-config.addon.mjs +22 -4
- package/dist/builtins/winston-logging/index.js +14 -5
- package/dist/builtins/winston-logging/index.mjs +14 -5
- package/dist/{composition-sources-BIT8IUKm.js → composition-sources-B4jC2FC7.js} +1 -1
- package/dist/{composition-sources-tpYR0f1x.mjs → composition-sources-BGOSCGWa.mjs} +1 -1
- package/dist/{constants-Bc6trhoW.mjs → constants-B92BjObl.mjs} +1 -1
- package/dist/{constants-CwRY32Nx.js → constants-BRsjQwi-.js} +1 -1
- package/dist/{device-ca-BhdBByGD.mjs → device-ca-46BUsWD1.mjs} +2 -2
- package/dist/{device-ca-DImD8IzR.js → device-ca-DHG9OW2m.js} +2 -2
- package/dist/{dist-CEAyXW3Q.js → dist-BOWdLjoK.js} +341 -13
- package/dist/{dist-m5JkT8UN.mjs → dist-yI6kF6r6.mjs} +306 -14
- package/dist/file-host-worker.js +1 -1
- package/dist/file-host-worker.mjs +1 -1
- package/dist/{hub-mdns-ciao-CBLvq2oj.js → hub-mdns-ciao-D7S5AJRU.js} +377 -69
- package/dist/{hub-mdns-ciao-DMlQTdPU.mjs → hub-mdns-ciao-DGwVc2uh.mjs} +344 -72
- package/dist/i18n/catalog-registry.d.ts +35 -0
- package/dist/i18n/index.d.ts +2 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +698 -22
- package/dist/index.mjs +681 -24
- package/dist/kernel/gc-census.d.ts +18 -1
- package/dist/kernel/settings-view-types.d.ts +2 -0
- package/dist/kernel/transport/local-transport.d.ts +3 -0
- package/dist/kernel/transport/peer-answered-error.d.ts +5 -1
- package/dist/{lib-NNxHSOIE.js → lib-8oZrELLm.js} +1 -1
- package/dist/{lib-BeGzVQcd.mjs → lib-DK38ompL.mjs} +1 -1
- package/dist/{restore-archive-DNxAStrJ.mjs → restore-archive-CpdUO-uS.mjs} +1 -1
- package/dist/{restore-archive-C75srVbG.js → restore-archive-DiGiI6Jp.js} +1 -1
- package/dist/{retired-settings-keys-DNfV28R_.js → retired-settings-keys-CyQ7uvta.js} +1 -1
- package/dist/{retired-settings-keys-C5qP9QIf.mjs → retired-settings-keys-UsVtLOT0.mjs} +1 -1
- package/dist/tls/agent-https.d.ts +2 -2
- package/dist/tls/boot-tls.d.ts +6 -0
- package/dist/tls/cert-evaluation.d.ts +1 -1
- package/dist/tls/cert-issue.d.ts +5 -1
- package/dist/tls/cert-manager.d.ts +18 -0
- package/dist/tls/cert-name-constraints.d.ts +53 -0
- package/dist/tls/index.d.ts +5 -4
- package/dist/tls/tls-actions.d.ts +27 -7
- package/dist/tls/tls-status.d.ts +22 -0
- package/dist/tls/uploaded-cert.d.ts +36 -4
- package/dist/{wal-maintenance-Ch79gy9S.js → wal-maintenance-DEL_jeG0.js} +0 -0
- package/dist/{wal-maintenance-DvnVO5IK.mjs → wal-maintenance-xsvdT5Go.mjs} +0 -0
- package/dist/{x509.es-r7Ht1thA.js → x509.es-C4cOo48M.js} +36 -0
- package/dist/{x509.es-CDvj67p1.mjs → x509.es-DK__ETIe.mjs} +1 -1
- package/package.json +3 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { i as __require, o as __toESM, t as __commonJSMin } from "../../chunk-CNf5ZN-e.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { E as DEVICE_NONCE_TTL_MS, J as ScopedTokenSchema, Or as BaseAddon, Pt as deviceCredentialsCapability, T as DEVICE_ENROLLMENT_TTL_MS, X as SsoBridgeClaimsSchema, Yt as formatDeviceRevoker, a as ApiKeyRecordSchema, ar as userManagementCapability, dt as buildDeviceEnrollmentLink, ft as buildDeviceSignatureMessage, ot as authProviderCapability, tt as UserRecordSchema, vi as userError } from "../../dist-yI6kF6r6.mjs";
|
|
3
3
|
import { t as require_safe_buffer } from "../../safe-buffer-B1OjL1I9.mjs";
|
|
4
4
|
import { t as require_ms } from "../../ms-CgH2OFlD.mjs";
|
|
5
|
-
import { _ as setProcessJwtSigningKey, a as importDevicePublicKey, c as rebuildDeviceCaCertificate, d as JWT_SIGNING_KEY_REF, g as processJwtSigningKey, h as loadJwtSigningKey, i as generateDeviceCa, l as verifyDeviceLeaf, m as getProcessJwtSigningKeyState, n as DEVICE_CA_KEY_REF, o as issueDeviceLeaf, r as DEVICE_CA_SETTINGS_SECTION, s as loadDeviceCa, t as DEVICE_CA_FIELD, u as verifyDeviceSignature } from "../../device-ca-
|
|
5
|
+
import { _ as setProcessJwtSigningKey, a as importDevicePublicKey, c as rebuildDeviceCaCertificate, d as JWT_SIGNING_KEY_REF, g as processJwtSigningKey, h as loadJwtSigningKey, i as generateDeviceCa, l as verifyDeviceLeaf, m as getProcessJwtSigningKeyState, n as DEVICE_CA_KEY_REF, o as issueDeviceLeaf, r as DEVICE_CA_SETTINGS_SECTION, s as loadDeviceCa, t as DEVICE_CA_FIELD, u as verifyDeviceSignature } from "../../device-ca-46BUsWD1.mjs";
|
|
6
6
|
import * as crypto$1 from "node:crypto";
|
|
7
7
|
import { X509Certificate, createHash, randomUUID, timingSafeEqual } from "node:crypto";
|
|
8
8
|
import nodeCrypto from "crypto";
|
|
@@ -7066,9 +7066,9 @@ var AdminTokenManager = class {
|
|
|
7066
7066
|
/** Mint a token for `createdBy`. Refuses an expiry in the past or past 90 days. */
|
|
7067
7067
|
async create(input) {
|
|
7068
7068
|
const at = this.now();
|
|
7069
|
-
if (!(input.expiresAt > at) || input.expiresAt > at + 7776e6) throw
|
|
7069
|
+
if (!(input.expiresAt > at) || input.expiresAt > at + 7776e6) throw userError("system.admin-token-expiry-too-long", void 0, "An admin token must expire within 90 days");
|
|
7070
7070
|
const name = input.name.trim().slice(0, 80);
|
|
7071
|
-
if (name.length === 0) throw
|
|
7071
|
+
if (name.length === 0) throw userError("system.admin-token-name-required", void 0, "An admin token needs a name");
|
|
7072
7072
|
const token = `${ADMIN_TOKEN_PREFIX}${crypto$1.randomBytes(32).toString("base64url")}`;
|
|
7073
7073
|
const stored = {
|
|
7074
7074
|
id: crypto$1.randomUUID(),
|
|
@@ -7457,7 +7457,7 @@ var DeviceCredentialManager = class {
|
|
|
7457
7457
|
/** A one-shot code for `userId` (admin path). Returned once; only its hash is kept. */
|
|
7458
7458
|
startEnrollment(input) {
|
|
7459
7459
|
this.prune();
|
|
7460
|
-
if (this.pendingEnrollments.size >= MAX_PENDING) throw
|
|
7460
|
+
if (this.pendingEnrollments.size >= MAX_PENDING) throw userError("system.device-enrollment-busy", void 0, "Too many pending device enrollments — try again shortly");
|
|
7461
7461
|
const code = crypto$1.randomBytes(24).toString("base64url");
|
|
7462
7462
|
const expiresAt = this.now() + DEVICE_ENROLLMENT_TTL_MS;
|
|
7463
7463
|
this.pendingEnrollments.set(hash(code), {
|
|
@@ -8028,7 +8028,7 @@ var UserManager = class {
|
|
|
8028
8028
|
return this.storageAccess.getStore();
|
|
8029
8029
|
}
|
|
8030
8030
|
async create(input) {
|
|
8031
|
-
if (await this.findByUsername(input.username)) throw
|
|
8031
|
+
if (await this.findByUsername(input.username)) throw userError("system.user-exists", { username: String(input.username) }, `User with username "${input.username}" already exists`);
|
|
8032
8032
|
const passwordHash = await this.auth.hashPassword(input.password);
|
|
8033
8033
|
const now = Date.now();
|
|
8034
8034
|
const record = {
|
|
@@ -8080,7 +8080,7 @@ var UserManager = class {
|
|
|
8080
8080
|
}
|
|
8081
8081
|
async update(id, data) {
|
|
8082
8082
|
const existing = await this.findById(id);
|
|
8083
|
-
if (!existing) throw
|
|
8083
|
+
if (!existing) throw userError("system.user-not-found", { id: String(id) }, `User with id "${id}" not found`);
|
|
8084
8084
|
await this.store.update.mutate({
|
|
8085
8085
|
collection: USERS_COLLECTION$1,
|
|
8086
8086
|
id,
|
|
@@ -8099,7 +8099,7 @@ var UserManager = class {
|
|
|
8099
8099
|
}
|
|
8100
8100
|
async resetPassword(id, newPassword) {
|
|
8101
8101
|
const existing = await this.findById(id);
|
|
8102
|
-
if (!existing) throw
|
|
8102
|
+
if (!existing) throw userError("system.user-not-found", { id: String(id) }, `User with id "${id}" not found`);
|
|
8103
8103
|
const passwordHash = await this.auth.hashPassword(newPassword);
|
|
8104
8104
|
await this.store.update.mutate({
|
|
8105
8105
|
collection: USERS_COLLECTION$1,
|
|
@@ -11766,7 +11766,7 @@ var LocalAuthAddon = class extends BaseAddon {
|
|
|
11766
11766
|
},
|
|
11767
11767
|
confirmTotp: async (input) => {
|
|
11768
11768
|
if (!this.totpManager) throw new Error("TOTP management not available");
|
|
11769
|
-
if (!await this.totpManager.confirm(input.userId, input.code)) throw
|
|
11769
|
+
if (!await this.totpManager.confirm(input.userId, input.code)) throw userError("auth.totp-confirm-failed", void 0, "TOTP confirmation failed — code did not match");
|
|
11770
11770
|
return { success: true };
|
|
11771
11771
|
},
|
|
11772
11772
|
disableTotp: async (input) => {
|
|
@@ -11824,7 +11824,7 @@ var LocalAuthAddon = class extends BaseAddon {
|
|
|
11824
11824
|
/** The admin cap (`device-credentials`): list, enroll-by-QR, revoke, rename, settings. */
|
|
11825
11825
|
buildDeviceCredentialsProvider() {
|
|
11826
11826
|
const manager = () => {
|
|
11827
|
-
if (this.deviceCredentials === null) throw
|
|
11827
|
+
if (this.deviceCredentials === null) throw userError("device.credentials-unavailable", void 0, "Device credentials not available");
|
|
11828
11828
|
return this.deviceCredentials;
|
|
11829
11829
|
};
|
|
11830
11830
|
const hubOrigins = async () => {
|
|
@@ -11876,7 +11876,7 @@ var LocalAuthAddon = class extends BaseAddon {
|
|
|
11876
11876
|
},
|
|
11877
11877
|
revokeDeviceCredential: async (input) => {
|
|
11878
11878
|
const record = manager().get(input.id);
|
|
11879
|
-
if (record === void 0) throw
|
|
11879
|
+
if (record === void 0) throw userError("device.credential-not-found", { id: input.id }, `Device credential not found: ${input.id}`);
|
|
11880
11880
|
const revoked = await manager().revoke(input.id, formatDeviceRevoker({
|
|
11881
11881
|
kind: "admin",
|
|
11882
11882
|
userId: input.caller.userId
|
|
@@ -11947,7 +11947,7 @@ var LocalAuthAddon = class extends BaseAddon {
|
|
|
11947
11947
|
return this.loginSessions;
|
|
11948
11948
|
};
|
|
11949
11949
|
const devices = () => {
|
|
11950
|
-
if (this.deviceCredentials === null) throw
|
|
11950
|
+
if (this.deviceCredentials === null) throw userError("device.credentials-unavailable", void 0, "Device credentials not available");
|
|
11951
11951
|
return this.deviceCredentials;
|
|
11952
11952
|
};
|
|
11953
11953
|
return {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
3
|
-
const require_dist = require("../../dist-
|
|
4
|
-
const require_hub_mdns_ciao = require("../../hub-mdns-ciao-
|
|
3
|
+
const require_dist = require("../../dist-BOWdLjoK.js");
|
|
4
|
+
const require_hub_mdns_ciao = require("../../hub-mdns-ciao-D7S5AJRU.js");
|
|
5
5
|
let zod = require("zod");
|
|
6
6
|
let node_net = require("node:net");
|
|
7
7
|
let node_os = require("node:os");
|
|
@@ -900,6 +900,11 @@ var LocalNetworkAddon = class extends require_dist.BaseAddon {
|
|
|
900
900
|
this.putCertificateOnListener("upload");
|
|
901
901
|
return this.snapshotTls();
|
|
902
902
|
},
|
|
903
|
+
useStoredUploadedCertificate: async () => {
|
|
904
|
+
await require_hub_mdns_ciao.useStoredUploadedCertificate(this.tlsDataDir());
|
|
905
|
+
this.putCertificateOnListener("upload");
|
|
906
|
+
return this.snapshotTls();
|
|
907
|
+
},
|
|
903
908
|
downloadCa: async () => {
|
|
904
909
|
return { pem: this.snapshotTls().caCertPem ?? "" };
|
|
905
910
|
},
|
|
@@ -953,13 +958,16 @@ var LocalNetworkAddon = class extends require_dist.BaseAddon {
|
|
|
953
958
|
return this.schema({ sections: [{
|
|
954
959
|
id: "local-access",
|
|
955
960
|
title: "LAN HTTP",
|
|
961
|
+
titleKey: "server:globalSettings.s_local-access.title",
|
|
956
962
|
description: "Native apps on this Wi-Fi use http:// and skip the private certificate. The tunnel and this admin UI stay on HTTPS. Turn off once a publicly-trusted certificate covers the LAN name.",
|
|
963
|
+
descriptionKey: "server:globalSettings.s_local-access.description",
|
|
957
964
|
columns: 1,
|
|
958
965
|
fields: [
|
|
959
966
|
this.field({
|
|
960
967
|
type: "boolean",
|
|
961
968
|
key: "httpEnabled",
|
|
962
969
|
label: "Enable HTTP on the LAN",
|
|
970
|
+
labelKey: "server:globalSettings.s_local-access.httpEnabled.label",
|
|
963
971
|
style: "switch",
|
|
964
972
|
default: true
|
|
965
973
|
}),
|
|
@@ -967,7 +975,9 @@ var LocalNetworkAddon = class extends require_dist.BaseAddon {
|
|
|
967
975
|
type: "number",
|
|
968
976
|
key: "httpPort",
|
|
969
977
|
label: "HTTP port",
|
|
978
|
+
labelKey: "server:globalSettings.s_local-access.httpPort.label",
|
|
970
979
|
description: "Dedicated listener. Must not equal the HTTPS port (4443 by default).",
|
|
980
|
+
descriptionKey: "server:globalSettings.s_local-access.httpPort.description",
|
|
971
981
|
min: 1,
|
|
972
982
|
max: 65535,
|
|
973
983
|
step: 1,
|
|
@@ -981,7 +991,9 @@ var LocalNetworkAddon = class extends require_dist.BaseAddon {
|
|
|
981
991
|
type: "boolean",
|
|
982
992
|
key: "mdnsAdvertise",
|
|
983
993
|
label: "Announce this hub on the LAN (mDNS)",
|
|
994
|
+
labelKey: "server:globalSettings.s_local-access.mdnsAdvertise.label",
|
|
984
995
|
description: "Lets `camstack login` find the hub without an address. Advertises only the HTTPS address, never a secret. Needs UDP 5353 multicast to reach the LAN (host networking or a dedicated container IP).",
|
|
996
|
+
descriptionKey: "server:globalSettings.s_local-access.mdnsAdvertise.description",
|
|
985
997
|
style: "switch",
|
|
986
998
|
default: true
|
|
987
999
|
}),
|
|
@@ -989,7 +1001,9 @@ var LocalNetworkAddon = class extends require_dist.BaseAddon {
|
|
|
989
1001
|
type: "text",
|
|
990
1002
|
key: "localHostname",
|
|
991
1003
|
label: "Local hostname",
|
|
1004
|
+
labelKey: "server:globalSettings.s_local-access.localHostname.label",
|
|
992
1005
|
description: "Advertised to the viewer instead of the raw LAN IP, and added to the certificate SAN. Requires this name to resolve on the LAN (router DNS, mDNS, or a hosts file). Leave empty to keep using the IP.",
|
|
1006
|
+
descriptionKey: "server:globalSettings.s_local-access.localHostname.description",
|
|
993
1007
|
maxLength: 253,
|
|
994
1008
|
placeholder: "camstack.lan"
|
|
995
1009
|
})
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { $t as isAppLinkBase, F as HUB_MDNS_SERVICE_TYPE, Fn as resolveAppConnections, Hn as resolveNotificationTapAddress, I as HUB_MDNS_TXT_KEYS, On as pickAppLinkHub, Or as BaseAddon, U as NetworkTunnelStartedDataSchema, _t as checkRoleAddress, fn as localNetworkCapability, l as CAMSTACK_APP_LINK_ORIGIN, nn as isDefaultAppConnectionEndpoint, sr as validateCustomAddress, yi as EventCategory, zn as resolveHubAddressRoles } from "../../dist-yI6kF6r6.mjs";
|
|
2
|
+
import { P as readLanHttpState, a as storeUploadedCertificate, d as servedHttpsLeafFingerprint, g as readTlsMode, h as readTlsAccessStatus, i as revertToGeneratedCertificate, j as applyLanHttp, k as DEFAULT_LAN_HTTP_PORT, m as readExtraSans, n as applyCertificateToListener, o as useStoredUploadedCertificate, r as regenerateCertificate, t as createCiaoPublisher, v as writeExtraSans, w as ensureTlsCert } from "../../hub-mdns-ciao-DGwVc2uh.mjs";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
import { isIP } from "node:net";
|
|
5
5
|
import * as os$1 from "node:os";
|
|
@@ -897,6 +897,11 @@ var LocalNetworkAddon = class extends BaseAddon {
|
|
|
897
897
|
this.putCertificateOnListener("upload");
|
|
898
898
|
return this.snapshotTls();
|
|
899
899
|
},
|
|
900
|
+
useStoredUploadedCertificate: async () => {
|
|
901
|
+
await useStoredUploadedCertificate(this.tlsDataDir());
|
|
902
|
+
this.putCertificateOnListener("upload");
|
|
903
|
+
return this.snapshotTls();
|
|
904
|
+
},
|
|
900
905
|
downloadCa: async () => {
|
|
901
906
|
return { pem: this.snapshotTls().caCertPem ?? "" };
|
|
902
907
|
},
|
|
@@ -950,13 +955,16 @@ var LocalNetworkAddon = class extends BaseAddon {
|
|
|
950
955
|
return this.schema({ sections: [{
|
|
951
956
|
id: "local-access",
|
|
952
957
|
title: "LAN HTTP",
|
|
958
|
+
titleKey: "server:globalSettings.s_local-access.title",
|
|
953
959
|
description: "Native apps on this Wi-Fi use http:// and skip the private certificate. The tunnel and this admin UI stay on HTTPS. Turn off once a publicly-trusted certificate covers the LAN name.",
|
|
960
|
+
descriptionKey: "server:globalSettings.s_local-access.description",
|
|
954
961
|
columns: 1,
|
|
955
962
|
fields: [
|
|
956
963
|
this.field({
|
|
957
964
|
type: "boolean",
|
|
958
965
|
key: "httpEnabled",
|
|
959
966
|
label: "Enable HTTP on the LAN",
|
|
967
|
+
labelKey: "server:globalSettings.s_local-access.httpEnabled.label",
|
|
960
968
|
style: "switch",
|
|
961
969
|
default: true
|
|
962
970
|
}),
|
|
@@ -964,7 +972,9 @@ var LocalNetworkAddon = class extends BaseAddon {
|
|
|
964
972
|
type: "number",
|
|
965
973
|
key: "httpPort",
|
|
966
974
|
label: "HTTP port",
|
|
975
|
+
labelKey: "server:globalSettings.s_local-access.httpPort.label",
|
|
967
976
|
description: "Dedicated listener. Must not equal the HTTPS port (4443 by default).",
|
|
977
|
+
descriptionKey: "server:globalSettings.s_local-access.httpPort.description",
|
|
968
978
|
min: 1,
|
|
969
979
|
max: 65535,
|
|
970
980
|
step: 1,
|
|
@@ -978,7 +988,9 @@ var LocalNetworkAddon = class extends BaseAddon {
|
|
|
978
988
|
type: "boolean",
|
|
979
989
|
key: "mdnsAdvertise",
|
|
980
990
|
label: "Announce this hub on the LAN (mDNS)",
|
|
991
|
+
labelKey: "server:globalSettings.s_local-access.mdnsAdvertise.label",
|
|
981
992
|
description: "Lets `camstack login` find the hub without an address. Advertises only the HTTPS address, never a secret. Needs UDP 5353 multicast to reach the LAN (host networking or a dedicated container IP).",
|
|
993
|
+
descriptionKey: "server:globalSettings.s_local-access.mdnsAdvertise.description",
|
|
982
994
|
style: "switch",
|
|
983
995
|
default: true
|
|
984
996
|
}),
|
|
@@ -986,7 +998,9 @@ var LocalNetworkAddon = class extends BaseAddon {
|
|
|
986
998
|
type: "text",
|
|
987
999
|
key: "localHostname",
|
|
988
1000
|
label: "Local hostname",
|
|
1001
|
+
labelKey: "server:globalSettings.s_local-access.localHostname.label",
|
|
989
1002
|
description: "Advertised to the viewer instead of the raw LAN IP, and added to the certificate SAN. Requires this name to resolve on the LAN (router DNS, mDNS, or a hosts file). Leave empty to keep using the IP.",
|
|
1003
|
+
descriptionKey: "server:globalSettings.s_local-access.localHostname.description",
|
|
990
1004
|
maxLength: 253,
|
|
991
1005
|
placeholder: "camstack.lan"
|
|
992
1006
|
})
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-BOWdLjoK.js");
|
|
7
7
|
//#region src/builtins/loki-logging/loki-payload.ts
|
|
8
8
|
/**
|
|
9
9
|
* Loki rejects a label name that is not a valid Prometheus label
|
|
@@ -458,14 +458,18 @@ var LokiLoggingAddon = class extends require_dist.BaseAddon {
|
|
|
458
458
|
return this.schema({ sections: [{
|
|
459
459
|
id: "loki-logging",
|
|
460
460
|
title: "Loki",
|
|
461
|
+
titleKey: "server:globalSettings.s_loki-logging.title",
|
|
461
462
|
description: "Ship this node’s logs to a Grafana Loki instance. Independent of the rotated-file and console destinations. Turn it on or off with the Enable/Disable control on this destination — the same one every other destination uses.",
|
|
463
|
+
descriptionKey: "server:globalSettings.s_loki-logging.description",
|
|
462
464
|
columns: 2,
|
|
463
465
|
fields: [
|
|
464
466
|
this.field({
|
|
465
467
|
type: "text",
|
|
466
468
|
key: "url",
|
|
467
469
|
label: "Loki URL",
|
|
470
|
+
labelKey: "server:globalSettings.s_loki-logging.url.label",
|
|
468
471
|
description: "Base URL, e.g. http://loki:3100 — the /loki/api/v1/push path is added.",
|
|
472
|
+
descriptionKey: "server:globalSettings.s_loki-logging.url.description",
|
|
469
473
|
placeholder: "http://loki:3100",
|
|
470
474
|
default: ""
|
|
471
475
|
}),
|
|
@@ -473,23 +477,28 @@ var LokiLoggingAddon = class extends require_dist.BaseAddon {
|
|
|
473
477
|
type: "select",
|
|
474
478
|
key: "level",
|
|
475
479
|
label: "Minimum level",
|
|
480
|
+
labelKey: "server:globalSettings.s_loki-logging.level.label",
|
|
476
481
|
default: "info",
|
|
477
482
|
options: [
|
|
478
483
|
{
|
|
479
484
|
value: "debug",
|
|
480
|
-
label: "Debug"
|
|
485
|
+
label: "Debug",
|
|
486
|
+
labelKey: "server:globalSettings.s_loki-logging.level.o_debug.label"
|
|
481
487
|
},
|
|
482
488
|
{
|
|
483
489
|
value: "info",
|
|
484
|
-
label: "Info"
|
|
490
|
+
label: "Info",
|
|
491
|
+
labelKey: "server:globalSettings.s_loki-logging.level.o_info.label"
|
|
485
492
|
},
|
|
486
493
|
{
|
|
487
494
|
value: "warn",
|
|
488
|
-
label: "Warn"
|
|
495
|
+
label: "Warn",
|
|
496
|
+
labelKey: "server:globalSettings.s_loki-logging.level.o_warn.label"
|
|
489
497
|
},
|
|
490
498
|
{
|
|
491
499
|
value: "error",
|
|
492
|
-
label: "Error"
|
|
500
|
+
label: "Error",
|
|
501
|
+
labelKey: "server:globalSettings.s_loki-logging.level.o_error.label"
|
|
493
502
|
}
|
|
494
503
|
]
|
|
495
504
|
}),
|
|
@@ -497,14 +506,18 @@ var LokiLoggingAddon = class extends require_dist.BaseAddon {
|
|
|
497
506
|
type: "text",
|
|
498
507
|
key: "job",
|
|
499
508
|
label: "Job label",
|
|
509
|
+
labelKey: "server:globalSettings.s_loki-logging.job.label",
|
|
500
510
|
description: "The Loki `job` label. Keep it fixed — labels are indexed.",
|
|
511
|
+
descriptionKey: "server:globalSettings.s_loki-logging.job.description",
|
|
501
512
|
default: "camstack"
|
|
502
513
|
}),
|
|
503
514
|
this.field({
|
|
504
515
|
type: "text",
|
|
505
516
|
key: "extraLabels",
|
|
506
517
|
label: "Extra labels",
|
|
518
|
+
labelKey: "server:globalSettings.s_loki-logging.extraLabels.label",
|
|
507
519
|
description: "Static `key=value,key2=value2`. Low-cardinality only: per-entry values belong in the line body, and a high-cardinality label will bring Loki down.",
|
|
520
|
+
descriptionKey: "server:globalSettings.s_loki-logging.extraLabels.description",
|
|
508
521
|
placeholder: "env=home,site=garage",
|
|
509
522
|
default: ""
|
|
510
523
|
}),
|
|
@@ -512,27 +525,34 @@ var LokiLoggingAddon = class extends require_dist.BaseAddon {
|
|
|
512
525
|
type: "text",
|
|
513
526
|
key: "tenantId",
|
|
514
527
|
label: "Tenant ID",
|
|
528
|
+
labelKey: "server:globalSettings.s_loki-logging.tenantId.label",
|
|
515
529
|
description: "Sent as X-Scope-OrgID. Required by Grafana Cloud and multi-tenant Loki.",
|
|
530
|
+
descriptionKey: "server:globalSettings.s_loki-logging.tenantId.description",
|
|
516
531
|
default: ""
|
|
517
532
|
}),
|
|
518
533
|
this.field({
|
|
519
534
|
type: "text",
|
|
520
535
|
key: "username",
|
|
521
536
|
label: "Username",
|
|
537
|
+
labelKey: "server:globalSettings.s_loki-logging.username.label",
|
|
522
538
|
description: "HTTP basic auth. Leave empty for none.",
|
|
539
|
+
descriptionKey: "server:globalSettings.s_loki-logging.username.description",
|
|
523
540
|
default: ""
|
|
524
541
|
}),
|
|
525
542
|
this.field({
|
|
526
543
|
type: "password",
|
|
527
544
|
key: "password",
|
|
528
545
|
label: "Password",
|
|
546
|
+
labelKey: "server:globalSettings.s_loki-logging.password.label",
|
|
529
547
|
default: ""
|
|
530
548
|
}),
|
|
531
549
|
this.field({
|
|
532
550
|
type: "number",
|
|
533
551
|
key: "batchIntervalMs",
|
|
534
552
|
label: "Flush interval",
|
|
553
|
+
labelKey: "server:globalSettings.s_loki-logging.batchIntervalMs.label",
|
|
535
554
|
description: "How often a partial batch is pushed.",
|
|
555
|
+
descriptionKey: "server:globalSettings.s_loki-logging.batchIntervalMs.description",
|
|
536
556
|
min: 250,
|
|
537
557
|
max: 6e4,
|
|
538
558
|
step: 250,
|
|
@@ -543,7 +563,9 @@ var LokiLoggingAddon = class extends require_dist.BaseAddon {
|
|
|
543
563
|
type: "number",
|
|
544
564
|
key: "batchSize",
|
|
545
565
|
label: "Batch size",
|
|
566
|
+
labelKey: "server:globalSettings.s_loki-logging.batchSize.label",
|
|
546
567
|
description: "Push early once this many entries are queued.",
|
|
568
|
+
descriptionKey: "server:globalSettings.s_loki-logging.batchSize.description",
|
|
547
569
|
min: 1,
|
|
548
570
|
max: 5e3,
|
|
549
571
|
step: 10,
|
|
@@ -553,6 +575,7 @@ var LokiLoggingAddon = class extends require_dist.BaseAddon {
|
|
|
553
575
|
type: "number",
|
|
554
576
|
key: "timeoutMs",
|
|
555
577
|
label: "Request timeout",
|
|
578
|
+
labelKey: "server:globalSettings.s_loki-logging.timeoutMs.label",
|
|
556
579
|
min: 1e3,
|
|
557
580
|
max: 6e4,
|
|
558
581
|
step: 500,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Or as BaseAddon, mn as logDestinationCapability } from "../../dist-yI6kF6r6.mjs";
|
|
2
2
|
//#region src/builtins/loki-logging/loki-payload.ts
|
|
3
3
|
/**
|
|
4
4
|
* Loki rejects a label name that is not a valid Prometheus label
|
|
@@ -453,14 +453,18 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
453
453
|
return this.schema({ sections: [{
|
|
454
454
|
id: "loki-logging",
|
|
455
455
|
title: "Loki",
|
|
456
|
+
titleKey: "server:globalSettings.s_loki-logging.title",
|
|
456
457
|
description: "Ship this node’s logs to a Grafana Loki instance. Independent of the rotated-file and console destinations. Turn it on or off with the Enable/Disable control on this destination — the same one every other destination uses.",
|
|
458
|
+
descriptionKey: "server:globalSettings.s_loki-logging.description",
|
|
457
459
|
columns: 2,
|
|
458
460
|
fields: [
|
|
459
461
|
this.field({
|
|
460
462
|
type: "text",
|
|
461
463
|
key: "url",
|
|
462
464
|
label: "Loki URL",
|
|
465
|
+
labelKey: "server:globalSettings.s_loki-logging.url.label",
|
|
463
466
|
description: "Base URL, e.g. http://loki:3100 — the /loki/api/v1/push path is added.",
|
|
467
|
+
descriptionKey: "server:globalSettings.s_loki-logging.url.description",
|
|
464
468
|
placeholder: "http://loki:3100",
|
|
465
469
|
default: ""
|
|
466
470
|
}),
|
|
@@ -468,23 +472,28 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
468
472
|
type: "select",
|
|
469
473
|
key: "level",
|
|
470
474
|
label: "Minimum level",
|
|
475
|
+
labelKey: "server:globalSettings.s_loki-logging.level.label",
|
|
471
476
|
default: "info",
|
|
472
477
|
options: [
|
|
473
478
|
{
|
|
474
479
|
value: "debug",
|
|
475
|
-
label: "Debug"
|
|
480
|
+
label: "Debug",
|
|
481
|
+
labelKey: "server:globalSettings.s_loki-logging.level.o_debug.label"
|
|
476
482
|
},
|
|
477
483
|
{
|
|
478
484
|
value: "info",
|
|
479
|
-
label: "Info"
|
|
485
|
+
label: "Info",
|
|
486
|
+
labelKey: "server:globalSettings.s_loki-logging.level.o_info.label"
|
|
480
487
|
},
|
|
481
488
|
{
|
|
482
489
|
value: "warn",
|
|
483
|
-
label: "Warn"
|
|
490
|
+
label: "Warn",
|
|
491
|
+
labelKey: "server:globalSettings.s_loki-logging.level.o_warn.label"
|
|
484
492
|
},
|
|
485
493
|
{
|
|
486
494
|
value: "error",
|
|
487
|
-
label: "Error"
|
|
495
|
+
label: "Error",
|
|
496
|
+
labelKey: "server:globalSettings.s_loki-logging.level.o_error.label"
|
|
488
497
|
}
|
|
489
498
|
]
|
|
490
499
|
}),
|
|
@@ -492,14 +501,18 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
492
501
|
type: "text",
|
|
493
502
|
key: "job",
|
|
494
503
|
label: "Job label",
|
|
504
|
+
labelKey: "server:globalSettings.s_loki-logging.job.label",
|
|
495
505
|
description: "The Loki `job` label. Keep it fixed — labels are indexed.",
|
|
506
|
+
descriptionKey: "server:globalSettings.s_loki-logging.job.description",
|
|
496
507
|
default: "camstack"
|
|
497
508
|
}),
|
|
498
509
|
this.field({
|
|
499
510
|
type: "text",
|
|
500
511
|
key: "extraLabels",
|
|
501
512
|
label: "Extra labels",
|
|
513
|
+
labelKey: "server:globalSettings.s_loki-logging.extraLabels.label",
|
|
502
514
|
description: "Static `key=value,key2=value2`. Low-cardinality only: per-entry values belong in the line body, and a high-cardinality label will bring Loki down.",
|
|
515
|
+
descriptionKey: "server:globalSettings.s_loki-logging.extraLabels.description",
|
|
503
516
|
placeholder: "env=home,site=garage",
|
|
504
517
|
default: ""
|
|
505
518
|
}),
|
|
@@ -507,27 +520,34 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
507
520
|
type: "text",
|
|
508
521
|
key: "tenantId",
|
|
509
522
|
label: "Tenant ID",
|
|
523
|
+
labelKey: "server:globalSettings.s_loki-logging.tenantId.label",
|
|
510
524
|
description: "Sent as X-Scope-OrgID. Required by Grafana Cloud and multi-tenant Loki.",
|
|
525
|
+
descriptionKey: "server:globalSettings.s_loki-logging.tenantId.description",
|
|
511
526
|
default: ""
|
|
512
527
|
}),
|
|
513
528
|
this.field({
|
|
514
529
|
type: "text",
|
|
515
530
|
key: "username",
|
|
516
531
|
label: "Username",
|
|
532
|
+
labelKey: "server:globalSettings.s_loki-logging.username.label",
|
|
517
533
|
description: "HTTP basic auth. Leave empty for none.",
|
|
534
|
+
descriptionKey: "server:globalSettings.s_loki-logging.username.description",
|
|
518
535
|
default: ""
|
|
519
536
|
}),
|
|
520
537
|
this.field({
|
|
521
538
|
type: "password",
|
|
522
539
|
key: "password",
|
|
523
540
|
label: "Password",
|
|
541
|
+
labelKey: "server:globalSettings.s_loki-logging.password.label",
|
|
524
542
|
default: ""
|
|
525
543
|
}),
|
|
526
544
|
this.field({
|
|
527
545
|
type: "number",
|
|
528
546
|
key: "batchIntervalMs",
|
|
529
547
|
label: "Flush interval",
|
|
548
|
+
labelKey: "server:globalSettings.s_loki-logging.batchIntervalMs.label",
|
|
530
549
|
description: "How often a partial batch is pushed.",
|
|
550
|
+
descriptionKey: "server:globalSettings.s_loki-logging.batchIntervalMs.description",
|
|
531
551
|
min: 250,
|
|
532
552
|
max: 6e4,
|
|
533
553
|
step: 250,
|
|
@@ -538,7 +558,9 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
538
558
|
type: "number",
|
|
539
559
|
key: "batchSize",
|
|
540
560
|
label: "Batch size",
|
|
561
|
+
labelKey: "server:globalSettings.s_loki-logging.batchSize.label",
|
|
541
562
|
description: "Push early once this many entries are queued.",
|
|
563
|
+
descriptionKey: "server:globalSettings.s_loki-logging.batchSize.description",
|
|
542
564
|
min: 1,
|
|
543
565
|
max: 5e3,
|
|
544
566
|
step: 10,
|
|
@@ -548,6 +570,7 @@ var LokiLoggingAddon = class extends BaseAddon {
|
|
|
548
570
|
type: "number",
|
|
549
571
|
key: "timeoutMs",
|
|
550
572
|
label: "Request timeout",
|
|
573
|
+
labelKey: "server:globalSettings.s_loki-logging.timeoutMs.label",
|
|
551
574
|
min: 1e3,
|
|
552
575
|
max: 6e4,
|
|
553
576
|
step: 500,
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-BOWdLjoK.js");
|
|
7
7
|
let node_fs_promises = require("node:fs/promises");
|
|
8
8
|
let node_os = require("node:os");
|
|
9
9
|
node_os = require_chunk.__toESM(node_os);
|
|
@@ -3511,11 +3511,14 @@ var NativeMetricsAddon = class NativeMetricsAddon extends require_dist.BaseAddon
|
|
|
3511
3511
|
return this.schema({ sections: [{
|
|
3512
3512
|
id: "native-metrics-settings",
|
|
3513
3513
|
title: "System Metrics",
|
|
3514
|
+
titleKey: "server:globalSettings.s_native-metrics-settings.title",
|
|
3514
3515
|
fields: [this.field({
|
|
3515
3516
|
type: "number",
|
|
3516
3517
|
key: "samplingIntervalMs",
|
|
3517
3518
|
label: "Sampling Interval",
|
|
3519
|
+
labelKey: "server:globalSettings.s_native-metrics-settings.samplingIntervalMs.label",
|
|
3518
3520
|
description: "How often to collect system metrics",
|
|
3521
|
+
descriptionKey: "server:globalSettings.s_native-metrics-settings.samplingIntervalMs.description",
|
|
3519
3522
|
min: 1e3,
|
|
3520
3523
|
max: 6e4,
|
|
3521
3524
|
step: 1e3,
|
|
@@ -3525,12 +3528,15 @@ var NativeMetricsAddon = class NativeMetricsAddon extends require_dist.BaseAddon
|
|
|
3525
3528
|
}, {
|
|
3526
3529
|
id: "native-metrics-load-series",
|
|
3527
3530
|
title: "Load history",
|
|
3531
|
+
titleKey: "server:globalSettings.s_native-metrics-load-series.title",
|
|
3528
3532
|
fields: [
|
|
3529
3533
|
this.field({
|
|
3530
3534
|
type: "number",
|
|
3531
3535
|
key: "loadSeriesCadenceSec",
|
|
3532
3536
|
label: "Sampling cadence",
|
|
3537
|
+
labelKey: "server:globalSettings.s_native-metrics-load-series.loadSeriesCadenceSec.label",
|
|
3533
3538
|
description: "How often every node reports its process tree. FIXED — a sample is emitted on every interval whether or not anything changed, so a gap in the chart means one thing only: nobody reported. Outside 5-60 s the value is refused.",
|
|
3539
|
+
descriptionKey: "server:globalSettings.s_native-metrics-load-series.loadSeriesCadenceSec.description",
|
|
3534
3540
|
min: 5,
|
|
3535
3541
|
max: 60,
|
|
3536
3542
|
step: 1,
|
|
@@ -3541,7 +3547,9 @@ var NativeMetricsAddon = class NativeMetricsAddon extends require_dist.BaseAddon
|
|
|
3541
3547
|
type: "number",
|
|
3542
3548
|
key: "loadSeriesRetentionHours",
|
|
3543
3549
|
label: "Retention",
|
|
3550
|
+
labelKey: "server:globalSettings.s_native-metrics-load-series.loadSeriesRetentionHours.label",
|
|
3544
3551
|
description: "How long the load history is kept on disk (the hub database, on the NVMe cache — never the recordings disk). This is the INTENTION; the row cap below is the guarantee.",
|
|
3552
|
+
descriptionKey: "server:globalSettings.s_native-metrics-load-series.loadSeriesRetentionHours.description",
|
|
3545
3553
|
min: 1,
|
|
3546
3554
|
max: 72,
|
|
3547
3555
|
step: 1,
|
|
@@ -3552,6 +3560,7 @@ var NativeMetricsAddon = class NativeMetricsAddon extends require_dist.BaseAddon
|
|
|
3552
3560
|
type: "info",
|
|
3553
3561
|
key: "load-series-cost",
|
|
3554
3562
|
label: "What this configuration costs",
|
|
3563
|
+
labelKey: "server:globalSettings.s_native-metrics-load-series.load-series-cost.label",
|
|
3555
3564
|
content: describeLoadSeriesCost(projection),
|
|
3556
3565
|
variant: projection.capBites ? "warning" : "info"
|
|
3557
3566
|
},
|
|
@@ -3559,6 +3568,7 @@ var NativeMetricsAddon = class NativeMetricsAddon extends require_dist.BaseAddon
|
|
|
3559
3568
|
type: "info",
|
|
3560
3569
|
key: "load-series-cap",
|
|
3561
3570
|
label: "Hard row cap",
|
|
3571
|
+
labelKey: "server:globalSettings.s_native-metrics-load-series.load-series-cap.label",
|
|
3562
3572
|
content: `The table never exceeds ${this.loadConfig.maxRows.toLocaleString("en-US")} rows. When it would, the OLDEST samples are evicted and a warning is logged — so raising the retention can never turn into an incident, only into a shorter effective window.`,
|
|
3563
3573
|
variant: "info"
|
|
3564
3574
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Dr as errMsg, In as resolveBucketMs, Jt as foldSnapshotByFunction, Nn as reducePoints, Or as BaseAddon, Wr as createEvent, bn as metricsProviderCapability, yi as EventCategory } from "../../dist-yI6kF6r6.mjs";
|
|
2
2
|
import { access, readFile, readdir } from "node:fs/promises";
|
|
3
3
|
import * as os$1 from "node:os";
|
|
4
4
|
import { platform } from "node:os";
|
|
@@ -3506,11 +3506,14 @@ var NativeMetricsAddon = class NativeMetricsAddon extends BaseAddon {
|
|
|
3506
3506
|
return this.schema({ sections: [{
|
|
3507
3507
|
id: "native-metrics-settings",
|
|
3508
3508
|
title: "System Metrics",
|
|
3509
|
+
titleKey: "server:globalSettings.s_native-metrics-settings.title",
|
|
3509
3510
|
fields: [this.field({
|
|
3510
3511
|
type: "number",
|
|
3511
3512
|
key: "samplingIntervalMs",
|
|
3512
3513
|
label: "Sampling Interval",
|
|
3514
|
+
labelKey: "server:globalSettings.s_native-metrics-settings.samplingIntervalMs.label",
|
|
3513
3515
|
description: "How often to collect system metrics",
|
|
3516
|
+
descriptionKey: "server:globalSettings.s_native-metrics-settings.samplingIntervalMs.description",
|
|
3514
3517
|
min: 1e3,
|
|
3515
3518
|
max: 6e4,
|
|
3516
3519
|
step: 1e3,
|
|
@@ -3520,12 +3523,15 @@ var NativeMetricsAddon = class NativeMetricsAddon extends BaseAddon {
|
|
|
3520
3523
|
}, {
|
|
3521
3524
|
id: "native-metrics-load-series",
|
|
3522
3525
|
title: "Load history",
|
|
3526
|
+
titleKey: "server:globalSettings.s_native-metrics-load-series.title",
|
|
3523
3527
|
fields: [
|
|
3524
3528
|
this.field({
|
|
3525
3529
|
type: "number",
|
|
3526
3530
|
key: "loadSeriesCadenceSec",
|
|
3527
3531
|
label: "Sampling cadence",
|
|
3532
|
+
labelKey: "server:globalSettings.s_native-metrics-load-series.loadSeriesCadenceSec.label",
|
|
3528
3533
|
description: "How often every node reports its process tree. FIXED — a sample is emitted on every interval whether or not anything changed, so a gap in the chart means one thing only: nobody reported. Outside 5-60 s the value is refused.",
|
|
3534
|
+
descriptionKey: "server:globalSettings.s_native-metrics-load-series.loadSeriesCadenceSec.description",
|
|
3529
3535
|
min: 5,
|
|
3530
3536
|
max: 60,
|
|
3531
3537
|
step: 1,
|
|
@@ -3536,7 +3542,9 @@ var NativeMetricsAddon = class NativeMetricsAddon extends BaseAddon {
|
|
|
3536
3542
|
type: "number",
|
|
3537
3543
|
key: "loadSeriesRetentionHours",
|
|
3538
3544
|
label: "Retention",
|
|
3545
|
+
labelKey: "server:globalSettings.s_native-metrics-load-series.loadSeriesRetentionHours.label",
|
|
3539
3546
|
description: "How long the load history is kept on disk (the hub database, on the NVMe cache — never the recordings disk). This is the INTENTION; the row cap below is the guarantee.",
|
|
3547
|
+
descriptionKey: "server:globalSettings.s_native-metrics-load-series.loadSeriesRetentionHours.description",
|
|
3540
3548
|
min: 1,
|
|
3541
3549
|
max: 72,
|
|
3542
3550
|
step: 1,
|
|
@@ -3547,6 +3555,7 @@ var NativeMetricsAddon = class NativeMetricsAddon extends BaseAddon {
|
|
|
3547
3555
|
type: "info",
|
|
3548
3556
|
key: "load-series-cost",
|
|
3549
3557
|
label: "What this configuration costs",
|
|
3558
|
+
labelKey: "server:globalSettings.s_native-metrics-load-series.load-series-cost.label",
|
|
3550
3559
|
content: describeLoadSeriesCost(projection),
|
|
3551
3560
|
variant: projection.capBites ? "warning" : "info"
|
|
3552
3561
|
},
|
|
@@ -3554,6 +3563,7 @@ var NativeMetricsAddon = class NativeMetricsAddon extends BaseAddon {
|
|
|
3554
3563
|
type: "info",
|
|
3555
3564
|
key: "load-series-cap",
|
|
3556
3565
|
label: "Hard row cap",
|
|
3566
|
+
labelKey: "server:globalSettings.s_native-metrics-load-series.load-series-cap.label",
|
|
3557
3567
|
content: `The table never exceeds ${this.loadConfig.maxRows.toLocaleString("en-US")} rows. When it would, the OLDEST samples are evicted and a warning is logged — so raising the retention can never turn into an incident, only into a shorter effective window.`,
|
|
3558
3568
|
variant: "info"
|
|
3559
3569
|
}
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
const require_chunk = require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-BOWdLjoK.js");
|
|
7
7
|
let node_os = require("node:os");
|
|
8
8
|
node_os = require_chunk.__toESM(node_os);
|
|
9
9
|
let node_fs = require("node:fs");
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { o as __toESM, r as __exportAll } from "../../chunk-CNf5ZN-e.mjs";
|
|
2
|
-
import {
|
|
2
|
+
import { An as platformProbeCapability, Dr as errMsg, Jr as emitReadiness, Kn as scoreRuntimes, Or as BaseAddon, yi as EventCategory, zt as enumerateInferenceDevices } from "../../dist-yI6kF6r6.mjs";
|
|
3
3
|
import * as os$1 from "node:os";
|
|
4
4
|
import * as fs from "node:fs";
|
|
5
5
|
import { execFile } from "node:child_process";
|
|
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
|
|
|
3
3
|
[Symbol.toStringTag]: { value: "Module" }
|
|
4
4
|
});
|
|
5
5
|
require("../../chunk-Cek0wNdY.js");
|
|
6
|
-
const require_dist = require("../../dist-
|
|
6
|
+
const require_dist = require("../../dist-BOWdLjoK.js");
|
|
7
7
|
//#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
|
|
8
8
|
/**
|
|
9
9
|
* Reconcile the durable `enabledProviders` set against authoritative
|