@hoknie/aip 0.4.0 → 0.5.0
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/.claude-plugin/marketplace.json +3 -0
- package/dist/app/actors.js +82 -0
- package/dist/app/actors.js.map +1 -0
- package/dist/app/application.js +71 -56
- package/dist/app/application.js.map +1 -1
- package/dist/app/integration-operations.js +34 -0
- package/dist/app/integration-operations.js.map +1 -0
- package/dist/app/lifecycle.js +91 -2
- package/dist/app/lifecycle.js.map +1 -1
- package/dist/app/notifications/index.js +44 -0
- package/dist/app/notifications/index.js.map +1 -0
- package/dist/app/oidc.js +27 -0
- package/dist/app/oidc.js.map +1 -0
- package/dist/app/saml.js +43 -0
- package/dist/app/saml.js.map +1 -0
- package/dist/app/timings.js +2 -1
- package/dist/app/timings.js.map +1 -1
- package/dist/app/wire.js +88 -0
- package/dist/app/wire.js.map +1 -0
- package/dist/app/wiring.js +10 -0
- package/dist/app/wiring.js.map +1 -1
- package/dist/cli/main.js +42 -0
- package/dist/cli/main.js.map +1 -1
- package/dist/feature/access/services/access.js +73 -0
- package/dist/feature/access/services/access.js.map +1 -0
- package/dist/feature/access/services/create.js +31 -0
- package/dist/feature/access/services/create.js.map +1 -0
- package/dist/feature/access/services/index.js +3 -0
- package/dist/feature/access/services/index.js.map +1 -0
- package/dist/feature/access/types/actions.js +145 -0
- package/dist/feature/access/types/actions.js.map +1 -0
- package/dist/feature/access/types/evaluate.js +58 -0
- package/dist/feature/access/types/evaluate.js.map +1 -0
- package/dist/feature/access/types/index.js +4 -0
- package/dist/feature/access/types/index.js.map +1 -0
- package/dist/feature/access/types/presets.js +41 -0
- package/dist/feature/access/types/presets.js.map +1 -0
- package/dist/feature/agents/clients/agy/runtime.js +1 -0
- package/dist/feature/agents/clients/agy/runtime.js.map +1 -1
- package/dist/feature/agents/clients/claude/permissions.js +5 -2
- package/dist/feature/agents/clients/claude/permissions.js.map +1 -1
- package/dist/feature/agents/clients/claude/runtime.js +2 -0
- package/dist/feature/agents/clients/claude/runtime.js.map +1 -1
- package/dist/feature/agents/clients/cline/runtime.js +1 -0
- package/dist/feature/agents/clients/cline/runtime.js.map +1 -1
- package/dist/feature/agents/clients/codex/runtime.js +1 -0
- package/dist/feature/agents/clients/codex/runtime.js.map +1 -1
- package/dist/feature/agents/clients/copilot/runtime.js +1 -0
- package/dist/feature/agents/clients/copilot/runtime.js.map +1 -1
- package/dist/feature/agents/clients/kilo/runtime.js +1 -0
- package/dist/feature/agents/clients/kilo/runtime.js.map +1 -1
- package/dist/feature/agents/clients/opencode/runtime.js +1 -0
- package/dist/feature/agents/clients/opencode/runtime.js.map +1 -1
- package/dist/feature/agents/services/skills.js +4 -1
- package/dist/feature/agents/services/skills.js.map +1 -1
- package/dist/feature/agents/services/supervisor.js +7 -3
- package/dist/feature/agents/services/supervisor.js.map +1 -1
- package/dist/feature/agents/types/mcp/env.js +6 -1
- package/dist/feature/agents/types/mcp/env.js.map +1 -1
- package/dist/feature/agents/types/message.js +13 -1
- package/dist/feature/agents/types/message.js.map +1 -1
- package/dist/feature/agents/types/runtime.js.map +1 -1
- package/dist/feature/agents/types/worker-tools.js +6 -1
- package/dist/feature/agents/types/worker-tools.js.map +1 -1
- package/dist/feature/audit/repositories/events.js +66 -0
- package/dist/feature/audit/repositories/events.js.map +1 -0
- package/dist/feature/audit/repositories/index.js +2 -0
- package/dist/feature/audit/repositories/index.js.map +1 -0
- package/dist/feature/audit/services/audit-log.js +24 -0
- package/dist/feature/audit/services/audit-log.js.map +1 -0
- package/dist/feature/audit/services/create.js +6 -0
- package/dist/feature/audit/services/create.js.map +1 -0
- package/dist/feature/audit/services/index.js +3 -0
- package/dist/feature/audit/services/index.js.map +1 -0
- package/dist/feature/audit/types/event.js +12 -0
- package/dist/feature/audit/types/event.js.map +1 -0
- package/dist/feature/audit/types/index.js +2 -0
- package/dist/feature/audit/types/index.js.map +1 -0
- package/dist/feature/compose/services/repository-move.js +8 -1
- package/dist/feature/compose/services/repository-move.js.map +1 -1
- package/dist/feature/compose/services/repository-removal.js +6 -1
- package/dist/feature/compose/services/repository-removal.js.map +1 -1
- package/dist/feature/delivery/ports/authors.js +2 -0
- package/dist/feature/delivery/ports/authors.js.map +1 -0
- package/dist/feature/delivery/services/commit-stamp.js +20 -0
- package/dist/feature/delivery/services/commit-stamp.js.map +1 -0
- package/dist/feature/delivery/services/create.js +6 -2
- package/dist/feature/delivery/services/create.js.map +1 -1
- package/dist/feature/delivery/services/deliver.js +8 -0
- package/dist/feature/delivery/services/deliver.js.map +1 -1
- package/dist/feature/delivery/services/push.js +23 -0
- package/dist/feature/delivery/services/push.js.map +1 -0
- package/dist/feature/delivery/types/index.js +2 -0
- package/dist/feature/delivery/types/index.js.map +1 -1
- package/dist/feature/delivery/types/remote-url.js +44 -0
- package/dist/feature/delivery/types/remote-url.js.map +1 -0
- package/dist/feature/delivery/types/trailer.js +22 -0
- package/dist/feature/delivery/types/trailer.js.map +1 -0
- package/dist/feature/identity/clients/oidc/client.js +78 -0
- package/dist/feature/identity/clients/oidc/client.js.map +1 -0
- package/dist/feature/identity/clients/oidc/index.js +2 -0
- package/dist/feature/identity/clients/oidc/index.js.map +1 -0
- package/dist/feature/identity/clients/oidc/signature.js +51 -0
- package/dist/feature/identity/clients/oidc/signature.js.map +1 -0
- package/dist/feature/identity/clients/saml/client.js +108 -0
- package/dist/feature/identity/clients/saml/client.js.map +1 -0
- package/dist/feature/identity/clients/saml/idp-metadata.js +123 -0
- package/dist/feature/identity/clients/saml/idp-metadata.js.map +1 -0
- package/dist/feature/identity/clients/saml/index.js +3 -0
- package/dist/feature/identity/clients/saml/index.js.map +1 -0
- package/dist/feature/identity/ports/clock.js +2 -0
- package/dist/feature/identity/ports/clock.js.map +1 -0
- package/dist/feature/identity/ports/index.js +2 -0
- package/dist/feature/identity/ports/index.js.map +1 -0
- package/dist/feature/identity/ports/oidc.js +2 -0
- package/dist/feature/identity/ports/oidc.js.map +1 -0
- package/dist/feature/identity/ports/saml.js +2 -0
- package/dist/feature/identity/ports/saml.js.map +1 -0
- package/dist/feature/identity/repositories/index.js +7 -0
- package/dist/feature/identity/repositories/index.js.map +1 -0
- package/dist/feature/identity/repositories/links.js +57 -0
- package/dist/feature/identity/repositories/links.js.map +1 -0
- package/dist/feature/identity/repositories/saml-assertions.js +16 -0
- package/dist/feature/identity/repositories/saml-assertions.js.map +1 -0
- package/dist/feature/identity/repositories/sessions.js +27 -0
- package/dist/feature/identity/repositories/sessions.js.map +1 -0
- package/dist/feature/identity/repositories/sso-requests.js +34 -0
- package/dist/feature/identity/repositories/sso-requests.js.map +1 -0
- package/dist/feature/identity/repositories/tokens.js +55 -0
- package/dist/feature/identity/repositories/tokens.js.map +1 -0
- package/dist/feature/identity/repositories/users.js +75 -0
- package/dist/feature/identity/repositories/users.js.map +1 -0
- package/dist/feature/identity/services/cli-login.js +48 -0
- package/dist/feature/identity/services/cli-login.js.map +1 -0
- package/dist/feature/identity/services/create.js +76 -0
- package/dist/feature/identity/services/create.js.map +1 -0
- package/dist/feature/identity/services/index.js +10 -0
- package/dist/feature/identity/services/index.js.map +1 -0
- package/dist/feature/identity/services/saml.js +115 -0
- package/dist/feature/identity/services/saml.js.map +1 -0
- package/dist/feature/identity/services/sessions.js +81 -0
- package/dist/feature/identity/services/sessions.js.map +1 -0
- package/dist/feature/identity/services/sso-accounts.js +46 -0
- package/dist/feature/identity/services/sso-accounts.js.map +1 -0
- package/dist/feature/identity/services/sso.js +120 -0
- package/dist/feature/identity/services/sso.js.map +1 -0
- package/dist/feature/identity/services/system.js +15 -0
- package/dist/feature/identity/services/system.js.map +1 -0
- package/dist/feature/identity/services/tokens.js +74 -0
- package/dist/feature/identity/services/tokens.js.map +1 -0
- package/dist/feature/identity/services/users.js +103 -0
- package/dist/feature/identity/services/users.js.map +1 -0
- package/dist/feature/identity/types/claims.js +39 -0
- package/dist/feature/identity/types/claims.js.map +1 -0
- package/dist/feature/identity/types/index.js +5 -0
- package/dist/feature/identity/types/index.js.map +1 -0
- package/dist/feature/identity/types/token.js +11 -0
- package/dist/feature/identity/types/token.js.map +1 -0
- package/dist/feature/identity/types/ttl.js +19 -0
- package/dist/feature/identity/types/ttl.js.map +1 -0
- package/dist/feature/identity/types/user.js +47 -0
- package/dist/feature/identity/types/user.js.map +1 -0
- package/dist/feature/integrations/ports/adapter.js +2 -0
- package/dist/feature/integrations/ports/adapter.js.map +1 -0
- package/dist/feature/integrations/ports/changes.js +2 -0
- package/dist/feature/integrations/ports/changes.js.map +1 -0
- package/dist/feature/integrations/ports/index.js +5 -0
- package/dist/feature/integrations/ports/index.js.map +1 -0
- package/dist/feature/integrations/ports/operations.js +2 -0
- package/dist/feature/integrations/ports/operations.js.map +1 -0
- package/dist/feature/integrations/ports/secrets.js +2 -0
- package/dist/feature/integrations/ports/secrets.js.map +1 -0
- package/dist/feature/integrations/repositories/connections.js +89 -0
- package/dist/feature/integrations/repositories/connections.js.map +1 -0
- package/dist/feature/integrations/repositories/deliveries.js +56 -0
- package/dist/feature/integrations/repositories/deliveries.js.map +1 -0
- package/dist/feature/integrations/repositories/index.js +4 -0
- package/dist/feature/integrations/repositories/index.js.map +1 -0
- package/dist/feature/integrations/repositories/secrets.js +102 -0
- package/dist/feature/integrations/repositories/secrets.js.map +1 -0
- package/dist/feature/integrations/services/access.js +63 -0
- package/dist/feature/integrations/services/access.js.map +1 -0
- package/dist/feature/integrations/services/catalog.js +38 -0
- package/dist/feature/integrations/services/catalog.js.map +1 -0
- package/dist/feature/integrations/services/checks.js +66 -0
- package/dist/feature/integrations/services/checks.js.map +1 -0
- package/dist/feature/integrations/services/connections.js +189 -0
- package/dist/feature/integrations/services/connections.js.map +1 -0
- package/dist/feature/integrations/services/create.js +71 -0
- package/dist/feature/integrations/services/create.js.map +1 -0
- package/dist/feature/integrations/services/dispatch.js +162 -0
- package/dist/feature/integrations/services/dispatch.js.map +1 -0
- package/dist/feature/integrations/services/index.js +9 -0
- package/dist/feature/integrations/services/index.js.map +1 -0
- package/dist/feature/integrations/services/outbound.js +46 -0
- package/dist/feature/integrations/services/outbound.js.map +1 -0
- package/dist/feature/integrations/services/secrets.js +271 -0
- package/dist/feature/integrations/services/secrets.js.map +1 -0
- package/dist/feature/integrations/types/connection.js +81 -0
- package/dist/feature/integrations/types/connection.js.map +1 -0
- package/dist/feature/integrations/types/deliveries.js +5 -0
- package/dist/feature/integrations/types/deliveries.js.map +1 -0
- package/dist/feature/integrations/types/errors.js +58 -0
- package/dist/feature/integrations/types/errors.js.map +1 -0
- package/dist/feature/integrations/types/index.js +6 -0
- package/dist/feature/integrations/types/index.js.map +1 -0
- package/dist/feature/integrations/types/operations.js +16 -0
- package/dist/feature/integrations/types/operations.js.map +1 -0
- package/dist/feature/integrations/types/secrets.js +8 -0
- package/dist/feature/integrations/types/secrets.js.map +1 -0
- package/dist/feature/notifications/clients/index.js +7 -0
- package/dist/feature/notifications/clients/index.js.map +1 -0
- package/dist/feature/notifications/clients/slack/api.js +133 -0
- package/dist/feature/notifications/clients/slack/api.js.map +1 -0
- package/dist/feature/notifications/clients/slack/blocks.js +189 -0
- package/dist/feature/notifications/clients/slack/blocks.js.map +1 -0
- package/dist/feature/notifications/clients/slack/channel.js +219 -0
- package/dist/feature/notifications/clients/slack/channel.js.map +1 -0
- package/dist/feature/notifications/clients/slack/events.js +117 -0
- package/dist/feature/notifications/clients/slack/events.js.map +1 -0
- package/dist/feature/notifications/clients/slack/kind.js +39 -0
- package/dist/feature/notifications/clients/slack/kind.js.map +1 -0
- package/dist/feature/notifications/clients/slack/socket.js +141 -0
- package/dist/feature/notifications/clients/slack/socket.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/api.js +93 -0
- package/dist/feature/notifications/clients/telegram/api.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/channel.js +250 -0
- package/dist/feature/notifications/clients/telegram/channel.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/kind.js +34 -0
- package/dist/feature/notifications/clients/telegram/kind.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/render.js +68 -0
- package/dist/feature/notifications/clients/telegram/render.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/updates.js +71 -0
- package/dist/feature/notifications/clients/telegram/updates.js.map +1 -0
- package/dist/feature/notifications/clients/webhook/channel.js +131 -0
- package/dist/feature/notifications/clients/webhook/channel.js.map +1 -0
- package/dist/feature/notifications/clients/webhook/kind.js +52 -0
- package/dist/feature/notifications/clients/webhook/kind.js.map +1 -0
- package/dist/feature/notifications/clients/webhook/payload.js +96 -0
- package/dist/feature/notifications/clients/webhook/payload.js.map +1 -0
- package/dist/feature/notifications/clients/webhook/sign.js +15 -0
- package/dist/feature/notifications/clients/webhook/sign.js.map +1 -0
- package/dist/feature/notifications/ports/channel.js +2 -0
- package/dist/feature/notifications/ports/channel.js.map +1 -0
- package/dist/feature/notifications/ports/index.js +2 -0
- package/dist/feature/notifications/ports/index.js.map +1 -0
- package/dist/feature/notifications/ports/publish.js +2 -0
- package/dist/feature/notifications/ports/publish.js.map +1 -0
- package/dist/feature/notifications/repositories/answers.js +25 -0
- package/dist/feature/notifications/repositories/answers.js.map +1 -0
- package/dist/feature/notifications/repositories/attempts.js +34 -0
- package/dist/feature/notifications/repositories/attempts.js.map +1 -0
- package/dist/feature/notifications/repositories/cursors.js +25 -0
- package/dist/feature/notifications/repositories/cursors.js.map +1 -0
- package/dist/feature/notifications/repositories/deliveries.js +118 -0
- package/dist/feature/notifications/repositories/deliveries.js.map +1 -0
- package/dist/feature/notifications/repositories/index.js +7 -0
- package/dist/feature/notifications/repositories/index.js.map +1 -0
- package/dist/feature/notifications/repositories/outcomes.js +80 -0
- package/dist/feature/notifications/repositories/outcomes.js.map +1 -0
- package/dist/feature/notifications/repositories/subscriptions.js +85 -0
- package/dist/feature/notifications/repositories/subscriptions.js.map +1 -0
- package/dist/feature/notifications/services/channels.js +199 -0
- package/dist/feature/notifications/services/channels.js.map +1 -0
- package/dist/feature/notifications/services/closer.js +79 -0
- package/dist/feature/notifications/services/closer.js.map +1 -0
- package/dist/feature/notifications/services/create.js +116 -0
- package/dist/feature/notifications/services/create.js.map +1 -0
- package/dist/feature/notifications/services/dispatcher.js +210 -0
- package/dist/feature/notifications/services/dispatcher.js.map +1 -0
- package/dist/feature/notifications/services/drawing.js +27 -0
- package/dist/feature/notifications/services/drawing.js.map +1 -0
- package/dist/feature/notifications/services/factories.js +31 -0
- package/dist/feature/notifications/services/factories.js.map +1 -0
- package/dist/feature/notifications/services/inbound.js +172 -0
- package/dist/feature/notifications/services/inbound.js.map +1 -0
- package/dist/feature/notifications/services/index.js +10 -0
- package/dist/feature/notifications/services/index.js.map +1 -0
- package/dist/feature/notifications/services/journal.js +38 -0
- package/dist/feature/notifications/services/journal.js.map +1 -0
- package/dist/feature/notifications/services/lanes.js +28 -0
- package/dist/feature/notifications/services/lanes.js.map +1 -0
- package/dist/feature/notifications/services/outbox.js +2 -0
- package/dist/feature/notifications/services/outbox.js.map +1 -0
- package/dist/feature/notifications/services/sender.js +129 -0
- package/dist/feature/notifications/services/sender.js.map +1 -0
- package/dist/feature/notifications/services/senders/index.js +3 -0
- package/dist/feature/notifications/services/senders/index.js.map +1 -0
- package/dist/feature/notifications/services/senders/recent.js +32 -0
- package/dist/feature/notifications/services/senders/recent.js.map +1 -0
- package/dist/feature/notifications/services/senders/senders.js +23 -0
- package/dist/feature/notifications/services/senders/senders.js.map +1 -0
- package/dist/feature/notifications/services/subscriptions.js +221 -0
- package/dist/feature/notifications/services/subscriptions.js.map +1 -0
- package/dist/feature/notifications/services/webhooks/index.js +3 -0
- package/dist/feature/notifications/services/webhooks/index.js.map +1 -0
- package/dist/feature/notifications/services/webhooks/streaks.js +44 -0
- package/dist/feature/notifications/services/webhooks/streaks.js.map +1 -0
- package/dist/feature/notifications/services/webhooks/webhooks.js +249 -0
- package/dist/feature/notifications/services/webhooks/webhooks.js.map +1 -0
- package/dist/feature/notifications/types/answers.js +42 -0
- package/dist/feature/notifications/types/answers.js.map +1 -0
- package/dist/feature/notifications/types/channel.js +20 -0
- package/dist/feature/notifications/types/channel.js.map +1 -0
- package/dist/feature/notifications/types/display-url.js +11 -0
- package/dist/feature/notifications/types/display-url.js.map +1 -0
- package/dist/feature/notifications/types/drafts.js +35 -0
- package/dist/feature/notifications/types/drafts.js.map +1 -0
- package/dist/feature/notifications/types/errors.js +38 -0
- package/dist/feature/notifications/types/errors.js.map +1 -0
- package/dist/feature/notifications/types/events.js +137 -0
- package/dist/feature/notifications/types/events.js.map +1 -0
- package/dist/feature/notifications/types/index.js +13 -0
- package/dist/feature/notifications/types/index.js.map +1 -0
- package/dist/feature/notifications/types/limits.js +32 -0
- package/dist/feature/notifications/types/limits.js.map +1 -0
- package/dist/feature/notifications/types/model.js +29 -0
- package/dist/feature/notifications/types/model.js.map +1 -0
- package/dist/feature/notifications/types/render.js +132 -0
- package/dist/feature/notifications/types/render.js.map +1 -0
- package/dist/feature/notifications/types/retry.js +35 -0
- package/dist/feature/notifications/types/retry.js.map +1 -0
- package/dist/feature/notifications/types/texts.js +130 -0
- package/dist/feature/notifications/types/texts.js.map +1 -0
- package/dist/feature/notifications/types/webhooks.js +22 -0
- package/dist/feature/notifications/types/webhooks.js.map +1 -0
- package/dist/feature/queue/repositories/queues.js +6 -4
- package/dist/feature/queue/repositories/queues.js.map +1 -1
- package/dist/feature/queue/services/advance.js +2 -0
- package/dist/feature/queue/services/advance.js.map +1 -1
- package/dist/feature/queue/services/create.js +2 -0
- package/dist/feature/queue/services/create.js.map +1 -1
- package/dist/feature/queue/services/edit.js +2 -0
- package/dist/feature/queue/services/edit.js.map +1 -1
- package/dist/feature/queue/services/items.js +26 -47
- package/dist/feature/queue/services/items.js.map +1 -1
- package/dist/feature/queue/services/projects.js +22 -6
- package/dist/feature/queue/services/projects.js.map +1 -1
- package/dist/feature/queue/services/worker/tasks.js +108 -0
- package/dist/feature/queue/services/worker/tasks.js.map +1 -0
- package/dist/feature/queue/types/duplicates.js +46 -0
- package/dist/feature/queue/types/duplicates.js.map +1 -0
- package/dist/feature/queue/types/edit.js +2 -0
- package/dist/feature/queue/types/edit.js.map +1 -1
- package/dist/feature/queue/types/index.js +1 -0
- package/dist/feature/queue/types/index.js.map +1 -1
- package/dist/feature/queue/types/items.js.map +1 -1
- package/dist/feature/queue/types/limit-hits.js +2 -0
- package/dist/feature/queue/types/limit-hits.js.map +1 -1
- package/dist/feature/queue/types/returns.js +2 -0
- package/dist/feature/queue/types/returns.js.map +1 -1
- package/dist/feature/repos/services/projects.js +26 -2
- package/dist/feature/repos/services/projects.js.map +1 -1
- package/dist/feature/repos/types/index.js +1 -0
- package/dist/feature/repos/types/index.js.map +1 -1
- package/dist/feature/repos/types/remote.js +28 -0
- package/dist/feature/repos/types/remote.js.map +1 -0
- package/dist/feature/runs/machine/answers.js +13 -0
- package/dist/feature/runs/machine/answers.js.map +1 -1
- package/dist/feature/runs/machine/delivery-checks.js +4 -2
- package/dist/feature/runs/machine/delivery-checks.js.map +1 -1
- package/dist/feature/runs/machine/delivery-flow.js +3 -0
- package/dist/feature/runs/machine/delivery-flow.js.map +1 -1
- package/dist/feature/runs/machine/push/index.js +2 -0
- package/dist/feature/runs/machine/push/index.js.map +1 -0
- package/dist/feature/runs/machine/push/push.js +48 -0
- package/dist/feature/runs/machine/push/push.js.map +1 -0
- package/dist/feature/runs/machine/transition.js +21 -2
- package/dist/feature/runs/machine/transition.js.map +1 -1
- package/dist/feature/runs/ports/commits.js +2 -0
- package/dist/feature/runs/ports/commits.js.map +1 -0
- package/dist/feature/runs/ports/notify.js +2 -0
- package/dist/feature/runs/ports/notify.js.map +1 -0
- package/dist/feature/runs/ports/push.js +2 -0
- package/dist/feature/runs/ports/push.js.map +1 -0
- package/dist/feature/runs/ports/registry-project.js +2 -0
- package/dist/feature/runs/ports/registry-project.js.map +1 -0
- package/dist/feature/runs/ports/registry-skills.js +2 -0
- package/dist/feature/runs/ports/registry-skills.js.map +1 -0
- package/dist/feature/runs/ports/remote-mcp.js +2 -0
- package/dist/feature/runs/ports/remote-mcp.js.map +1 -0
- package/dist/feature/runs/repositories/finished-runs.js +5 -1
- package/dist/feature/runs/repositories/finished-runs.js.map +1 -1
- package/dist/feature/runs/repositories/rows.js +9 -0
- package/dist/feature/runs/repositories/rows.js.map +1 -1
- package/dist/feature/runs/repositories/write.js +4 -4
- package/dist/feature/runs/repositories/write.js.map +1 -1
- package/dist/feature/runs/services/create.js +1 -0
- package/dist/feature/runs/services/create.js.map +1 -1
- package/dist/feature/runs/services/effects/actions.js +2 -1
- package/dist/feature/runs/services/effects/actions.js.map +1 -1
- package/dist/feature/runs/services/effects/attempts.js +44 -54
- package/dist/feature/runs/services/effects/attempts.js.map +1 -1
- package/dist/feature/runs/services/effects/context.js +2 -0
- package/dist/feature/runs/services/effects/context.js.map +1 -1
- package/dist/feature/runs/services/effects/conversations.js +159 -1
- package/dist/feature/runs/services/effects/conversations.js.map +1 -1
- package/dist/feature/runs/services/effects/effects.js +2 -0
- package/dist/feature/runs/services/effects/effects.js.map +1 -1
- package/dist/feature/runs/services/effects/git.js +15 -2
- package/dist/feature/runs/services/effects/git.js.map +1 -1
- package/dist/feature/runs/services/effects/runtime-check.js +24 -0
- package/dist/feature/runs/services/effects/runtime-check.js.map +1 -1
- package/dist/feature/runs/services/effects/skills/index.js +3 -0
- package/dist/feature/runs/services/effects/skills/index.js.map +1 -0
- package/dist/feature/runs/services/effects/skills/outside-queue.js +58 -0
- package/dist/feature/runs/services/effects/skills/outside-queue.js.map +1 -0
- package/dist/feature/runs/services/effects/skills/registry.js +70 -0
- package/dist/feature/runs/services/effects/skills/registry.js.map +1 -0
- package/dist/feature/runs/services/engine.js +8 -1
- package/dist/feature/runs/services/engine.js.map +1 -1
- package/dist/feature/runs/services/index.js +1 -1
- package/dist/feature/runs/services/index.js.map +1 -1
- package/dist/feature/runs/services/reads.js +21 -1
- package/dist/feature/runs/services/reads.js.map +1 -1
- package/dist/feature/runs/services/requests.js +14 -4
- package/dist/feature/runs/services/requests.js.map +1 -1
- package/dist/feature/runs/services/states.js +2 -2
- package/dist/feature/runs/services/states.js.map +1 -1
- package/dist/feature/runs/types/answers/answers-text.js +7 -0
- package/dist/feature/runs/types/answers/answers-text.js.map +1 -0
- package/dist/feature/runs/types/constants.js +1 -1
- package/dist/feature/runs/types/constants.js.map +1 -1
- package/dist/feature/runs/types/create.js +5 -3
- package/dist/feature/runs/types/create.js.map +1 -1
- package/dist/feature/runs/types/index.js +1 -0
- package/dist/feature/runs/types/index.js.map +1 -1
- package/dist/feature/runs/types/problems.js +9 -5
- package/dist/feature/runs/types/problems.js.map +1 -1
- package/dist/feature/runs/types/run.js.map +1 -1
- package/dist/feature/runs/types/stage-status.js +3 -1
- package/dist/feature/runs/types/stage-status.js.map +1 -1
- package/dist/feature/service-registry/clients/http-mcp/client.js +164 -0
- package/dist/feature/service-registry/clients/http-mcp/client.js.map +1 -0
- package/dist/feature/service-registry/clients/http-mcp/index.js +2 -0
- package/dist/feature/service-registry/clients/http-mcp/index.js.map +1 -0
- package/dist/feature/service-registry/ports/adapter.js +2 -0
- package/dist/feature/service-registry/ports/adapter.js.map +1 -0
- package/dist/feature/service-registry/ports/index.js +3 -0
- package/dist/feature/service-registry/ports/index.js.map +1 -0
- package/dist/feature/service-registry/ports/transport.js +2 -0
- package/dist/feature/service-registry/ports/transport.js.map +1 -0
- package/dist/feature/service-registry/repositories/index.js +2 -0
- package/dist/feature/service-registry/repositories/index.js.map +1 -0
- package/dist/feature/service-registry/repositories/links.js +61 -0
- package/dist/feature/service-registry/repositories/links.js.map +1 -0
- package/dist/feature/service-registry/services/adapter.js +63 -0
- package/dist/feature/service-registry/services/adapter.js.map +1 -0
- package/dist/feature/service-registry/services/calls.js +86 -0
- package/dist/feature/service-registry/services/calls.js.map +1 -0
- package/dist/feature/service-registry/services/catalog-scan.js +49 -0
- package/dist/feature/service-registry/services/catalog-scan.js.map +1 -0
- package/dist/feature/service-registry/services/create.js +30 -0
- package/dist/feature/service-registry/services/create.js.map +1 -0
- package/dist/feature/service-registry/services/forwarder.js +107 -0
- package/dist/feature/service-registry/services/forwarder.js.map +1 -0
- package/dist/feature/service-registry/services/index.js +6 -0
- package/dist/feature/service-registry/services/index.js.map +1 -0
- package/dist/feature/service-registry/services/links.js +256 -0
- package/dist/feature/service-registry/services/links.js.map +1 -0
- package/dist/feature/service-registry/services/skill-cache.js +135 -0
- package/dist/feature/service-registry/services/skill-cache.js.map +1 -0
- package/dist/feature/service-registry/services/skill-source.js +128 -0
- package/dist/feature/service-registry/services/skill-source.js.map +1 -0
- package/dist/feature/service-registry/services/skills.js +197 -0
- package/dist/feature/service-registry/services/skills.js.map +1 -0
- package/dist/feature/service-registry/types/descriptor.js +41 -0
- package/dist/feature/service-registry/types/descriptor.js.map +1 -0
- package/dist/feature/service-registry/types/endpoint.js +2 -0
- package/dist/feature/service-registry/types/endpoint.js.map +1 -0
- package/dist/feature/service-registry/types/errors.js +26 -0
- package/dist/feature/service-registry/types/errors.js.map +1 -0
- package/dist/feature/service-registry/types/index.js +7 -0
- package/dist/feature/service-registry/types/index.js.map +1 -0
- package/dist/feature/service-registry/types/link.js +26 -0
- package/dist/feature/service-registry/types/link.js.map +1 -0
- package/dist/feature/service-registry/types/semver.js +2 -0
- package/dist/feature/service-registry/types/semver.js.map +1 -0
- package/dist/feature/service-registry/types/skills.js +27 -0
- package/dist/feature/service-registry/types/skills.js.map +1 -0
- package/dist/feature/stats/repositories/meta.js +10 -0
- package/dist/feature/stats/repositories/meta.js.map +1 -1
- package/dist/feature/stats/repositories/records.js +18 -7
- package/dist/feature/stats/repositories/records.js.map +1 -1
- package/dist/feature/stats/repositories/report.js +14 -4
- package/dist/feature/stats/repositories/report.js.map +1 -1
- package/dist/feature/stats/services/ledger.js +16 -1
- package/dist/feature/stats/services/ledger.js.map +1 -1
- package/dist/feature/stats/services/report.js +7 -2
- package/dist/feature/stats/services/report.js.map +1 -1
- package/dist/feature/stats/types/capture.js +3 -0
- package/dist/feature/stats/types/capture.js.map +1 -1
- package/dist/feature/stats/types/records.js.map +1 -1
- package/dist/feature/stats/types/report.js +2 -0
- package/dist/feature/stats/types/report.js.map +1 -1
- package/dist/feature/swarm-config/services/access/file.js +83 -0
- package/dist/feature/swarm-config/services/access/file.js.map +1 -0
- package/dist/feature/swarm-config/services/access/index.js +3 -0
- package/dist/feature/swarm-config/services/access/index.js.map +1 -0
- package/dist/feature/swarm-config/services/access/validate.js +134 -0
- package/dist/feature/swarm-config/services/access/validate.js.map +1 -0
- package/dist/feature/swarm-config/services/assemble.js +32 -1
- package/dist/feature/swarm-config/services/assemble.js.map +1 -1
- package/dist/feature/swarm-config/services/index.js +3 -2
- package/dist/feature/swarm-config/services/index.js.map +1 -1
- package/dist/feature/swarm-config/services/load.js +10 -1
- package/dist/feature/swarm-config/services/load.js.map +1 -1
- package/dist/feature/swarm-config/services/sections/mcp-servers.js +33 -5
- package/dist/feature/swarm-config/services/sections/mcp-servers.js.map +1 -1
- package/dist/feature/swarm-config/services/sections/server-saml.js +116 -0
- package/dist/feature/swarm-config/services/sections/server-saml.js.map +1 -0
- package/dist/feature/swarm-config/services/sections/server.js +272 -0
- package/dist/feature/swarm-config/services/sections/server.js.map +1 -0
- package/dist/feature/swarm-config/services/settings.js +25 -1
- package/dist/feature/swarm-config/services/settings.js.map +1 -1
- package/dist/feature/swarm-config/services/validate-settings.js +51 -3
- package/dist/feature/swarm-config/services/validate-settings.js.map +1 -1
- package/dist/feature/swarm-config/services/validate-specialists.js +23 -0
- package/dist/feature/swarm-config/services/validate-specialists.js.map +1 -1
- package/dist/feature/swarm-config/services/validate.js +30 -2
- package/dist/feature/swarm-config/services/validate.js.map +1 -1
- package/dist/feature/swarm-config/types/access/index.js +2 -0
- package/dist/feature/swarm-config/types/access/index.js.map +1 -0
- package/dist/feature/swarm-config/types/access/policy.js +10 -0
- package/dist/feature/swarm-config/types/access/policy.js.map +1 -0
- package/dist/feature/swarm-config/types/index.js +2 -0
- package/dist/feature/swarm-config/types/index.js.map +1 -1
- package/dist/feature/swarm-config/types/providers/provider.js +9 -0
- package/dist/feature/swarm-config/types/providers/provider.js.map +1 -1
- package/dist/feature/swarm-config/types/settings.js +31 -7
- package/dist/feature/swarm-config/types/settings.js.map +1 -1
- package/dist/feature/swarm-config/types/skills/index.js +3 -0
- package/dist/feature/swarm-config/types/skills/index.js.map +1 -0
- package/dist/feature/swarm-config/types/skills/semver.js +250 -0
- package/dist/feature/swarm-config/types/skills/semver.js.map +1 -0
- package/dist/feature/swarm-config/types/skills/skill-ref.js +35 -0
- package/dist/feature/swarm-config/types/skills/skill-ref.js.map +1 -0
- package/dist/feature/swarm-config/types/specialist.js +2 -0
- package/dist/feature/swarm-config/types/specialist.js.map +1 -1
- package/dist/feature/swarm-config/types/web/index.js +2 -0
- package/dist/feature/swarm-config/types/web/index.js.map +1 -0
- package/dist/feature/swarm-config/types/web/settings.js +14 -0
- package/dist/feature/swarm-config/types/web/settings.js.map +1 -0
- package/dist/feature/swarm-edit/services/mcp/editor-mcp.js +2 -0
- package/dist/feature/swarm-edit/services/mcp/editor-mcp.js.map +1 -1
- package/dist/feature/swarm-edit/services/plan-settings.js +2 -1
- package/dist/feature/swarm-edit/services/plan-settings.js.map +1 -1
- package/dist/feature/swarm-edit/services/references.js +2 -0
- package/dist/feature/swarm-edit/services/references.js.map +1 -1
- package/dist/feature/swarm-edit/types/editor.js.map +1 -1
- package/dist/feature/swarm-edit/types/setting-fields.js +1 -0
- package/dist/feature/swarm-edit/types/setting-fields.js.map +1 -1
- package/dist/platform/archive/index.js +2 -0
- package/dist/platform/archive/index.js.map +1 -0
- package/dist/platform/archive/zip.js +164 -0
- package/dist/platform/archive/zip.js.map +1 -0
- package/dist/platform/files/index.js +2 -0
- package/dist/platform/files/index.js.map +1 -0
- package/dist/platform/files/read.js +20 -0
- package/dist/platform/files/read.js.map +1 -0
- package/dist/platform/git/authorship.js +12 -0
- package/dist/platform/git/authorship.js.map +1 -0
- package/dist/platform/git/changes.js +26 -0
- package/dist/platform/git/changes.js.map +1 -0
- package/dist/platform/git/delivery.js +8 -20
- package/dist/platform/git/delivery.js.map +1 -1
- package/dist/platform/git/index.js +3 -0
- package/dist/platform/git/index.js.map +1 -1
- package/dist/platform/git/remote.js +69 -0
- package/dist/platform/git/remote.js.map +1 -0
- package/dist/platform/git/workspace.js +3 -4
- package/dist/platform/git/workspace.js.map +1 -1
- package/dist/platform/http/index.js +3 -0
- package/dist/platform/http/index.js.map +1 -0
- package/dist/platform/http/request.js +157 -0
- package/dist/platform/http/request.js.map +1 -0
- package/dist/platform/http/websocket-frames.js +155 -0
- package/dist/platform/http/websocket-frames.js.map +1 -0
- package/dist/platform/http/websocket.js +259 -0
- package/dist/platform/http/websocket.js.map +1 -0
- package/dist/platform/paths/index.js +1 -1
- package/dist/platform/paths/index.js.map +1 -1
- package/dist/platform/paths/paths.js +6 -0
- package/dist/platform/paths/paths.js.map +1 -1
- package/dist/platform/secrets/command.js +30 -0
- package/dist/platform/secrets/command.js.map +1 -0
- package/dist/platform/secrets/errors.js +16 -0
- package/dist/platform/secrets/errors.js.map +1 -0
- package/dist/platform/secrets/file-key.js +43 -0
- package/dist/platform/secrets/file-key.js.map +1 -0
- package/dist/platform/secrets/file.js +158 -0
- package/dist/platform/secrets/file.js.map +1 -0
- package/dist/platform/secrets/index.js +6 -0
- package/dist/platform/secrets/index.js.map +1 -0
- package/dist/platform/secrets/keyring.js +73 -0
- package/dist/platform/secrets/keyring.js.map +1 -0
- package/dist/platform/secrets/select.js +124 -0
- package/dist/platform/secrets/select.js.map +1 -0
- package/dist/platform/secrets/store.js +2 -0
- package/dist/platform/secrets/store.js.map +1 -0
- package/dist/platform/sqlite/authorship-migration.js +23 -0
- package/dist/platform/sqlite/authorship-migration.js.map +1 -0
- package/dist/platform/sqlite/identity-migration.js +52 -0
- package/dist/platform/sqlite/identity-migration.js.map +1 -0
- package/dist/platform/sqlite/integrations-migration.js +147 -0
- package/dist/platform/sqlite/integrations-migration.js.map +1 -0
- package/dist/platform/sqlite/parts.js +27 -0
- package/dist/platform/sqlite/parts.js.map +1 -1
- package/dist/platform/sqlite/saml-migration.js +9 -0
- package/dist/platform/sqlite/saml-migration.js.map +1 -0
- package/dist/platform/sqlite/sso-migration.js +17 -0
- package/dist/platform/sqlite/sso-migration.js.map +1 -0
- package/dist/platform/sqlite/stats-migration.js +8 -0
- package/dist/platform/sqlite/stats-migration.js.map +1 -1
- package/dist/presentation/cli/commands/daemon.js +5 -3
- package/dist/presentation/cli/commands/daemon.js.map +1 -1
- package/dist/presentation/cli/commands/integration/index.js +3 -0
- package/dist/presentation/cli/commands/integration/index.js.map +1 -0
- package/dist/presentation/cli/commands/integration/integrations.js +239 -0
- package/dist/presentation/cli/commands/integration/integrations.js.map +1 -0
- package/dist/presentation/cli/commands/integration/skills.js +24 -0
- package/dist/presentation/cli/commands/integration/skills.js.map +1 -0
- package/dist/presentation/cli/commands/mcp.js +23 -1
- package/dist/presentation/cli/commands/mcp.js.map +1 -1
- package/dist/presentation/cli/commands/notify/index.js +2 -0
- package/dist/presentation/cli/commands/notify/index.js.map +1 -0
- package/dist/presentation/cli/commands/notify/notify.js +145 -0
- package/dist/presentation/cli/commands/notify/notify.js.map +1 -0
- package/dist/presentation/cli/commands/queue-edit.js +0 -24
- package/dist/presentation/cli/commands/queue-edit.js.map +1 -1
- package/dist/presentation/cli/commands/queue.js +3 -3
- package/dist/presentation/cli/commands/queue.js.map +1 -1
- package/dist/presentation/cli/commands/run-delivery.js +23 -2
- package/dist/presentation/cli/commands/run-delivery.js.map +1 -1
- package/dist/presentation/cli/commands/run.js +26 -8
- package/dist/presentation/cli/commands/run.js.map +1 -1
- package/dist/presentation/cli/commands/server/access.js +43 -0
- package/dist/presentation/cli/commands/server/access.js.map +1 -0
- package/dist/presentation/cli/commands/server/admin.js +118 -0
- package/dist/presentation/cli/commands/server/admin.js.map +1 -0
- package/dist/presentation/cli/commands/server/apply.js +82 -0
- package/dist/presentation/cli/commands/server/apply.js.map +1 -0
- package/dist/presentation/cli/commands/server/audit.js +38 -0
- package/dist/presentation/cli/commands/server/audit.js.map +1 -0
- package/dist/presentation/cli/commands/server/login.js +141 -0
- package/dist/presentation/cli/commands/server/login.js.map +1 -0
- package/dist/presentation/cli/commands/server/profile.js +38 -0
- package/dist/presentation/cli/commands/server/profile.js.map +1 -0
- package/dist/presentation/cli/commands/server/register.js +12 -0
- package/dist/presentation/cli/commands/server/register.js.map +1 -0
- package/dist/presentation/cli/commands/server/repository.js +34 -0
- package/dist/presentation/cli/commands/server/repository.js.map +1 -0
- package/dist/presentation/cli/commands/stats.js +10 -1
- package/dist/presentation/cli/commands/stats.js.map +1 -1
- package/dist/presentation/cli/commands/web.js +26 -5
- package/dist/presentation/cli/commands/web.js.map +1 -1
- package/dist/presentation/cli/commands/webhook/index.js +2 -0
- package/dist/presentation/cli/commands/webhook/index.js.map +1 -0
- package/dist/presentation/cli/commands/webhook/webhook.js +172 -0
- package/dist/presentation/cli/commands/webhook/webhook.js.map +1 -0
- package/dist/presentation/cli/context.js +34 -2
- package/dist/presentation/cli/context.js.map +1 -1
- package/dist/presentation/cli/help.js +20 -1
- package/dist/presentation/cli/help.js.map +1 -1
- package/dist/presentation/cli/io.js.map +1 -1
- package/dist/presentation/cli/local/config-check-providers.js +11 -0
- package/dist/presentation/cli/local/config-check-providers.js.map +1 -1
- package/dist/presentation/cli/local/config-check.js +16 -8
- package/dist/presentation/cli/local/config-check.js.map +1 -1
- package/dist/presentation/cli/options.js +53 -0
- package/dist/presentation/cli/options.js.map +1 -1
- package/dist/presentation/cli/program.js +8 -0
- package/dist/presentation/cli/program.js.map +1 -1
- package/dist/presentation/cli/queue-add.js +53 -35
- package/dist/presentation/cli/queue-add.js.map +1 -1
- package/dist/presentation/cli/queue-print.js +34 -1
- package/dist/presentation/cli/queue-print.js.map +1 -1
- package/dist/presentation/cli/secret-keys.js +38 -0
- package/dist/presentation/cli/secret-keys.js.map +1 -0
- package/dist/presentation/format/access/access.js +30 -0
- package/dist/presentation/format/access/access.js.map +1 -0
- package/dist/presentation/format/access/index.js +2 -0
- package/dist/presentation/format/access/index.js.map +1 -0
- package/dist/presentation/format/audit/audit.js +29 -0
- package/dist/presentation/format/audit/audit.js.map +1 -0
- package/dist/presentation/format/audit/index.js +2 -0
- package/dist/presentation/format/audit/index.js.map +1 -0
- package/dist/presentation/format/index.js +5 -0
- package/dist/presentation/format/index.js.map +1 -1
- package/dist/presentation/format/integration/index.js +3 -0
- package/dist/presentation/format/integration/index.js.map +1 -0
- package/dist/presentation/format/integration/integrations.js +95 -0
- package/dist/presentation/format/integration/integrations.js.map +1 -0
- package/dist/presentation/format/integration/skills.js +17 -0
- package/dist/presentation/format/integration/skills.js.map +1 -0
- package/dist/presentation/format/notifications/index.js +2 -0
- package/dist/presentation/format/notifications/index.js.map +1 -0
- package/dist/presentation/format/notifications/notifications.js +44 -0
- package/dist/presentation/format/notifications/notifications.js.map +1 -0
- package/dist/presentation/format/overview.js +2 -1
- package/dist/presentation/format/overview.js.map +1 -1
- package/dist/presentation/format/providers/provider-list.js +4 -1
- package/dist/presentation/format/providers/provider-list.js.map +1 -1
- package/dist/presentation/format/queue.js +2 -1
- package/dist/presentation/format/queue.js.map +1 -1
- package/dist/presentation/format/runs.js +30 -2
- package/dist/presentation/format/runs.js.map +1 -1
- package/dist/presentation/format/stats.js +9 -3
- package/dist/presentation/format/stats.js.map +1 -1
- package/dist/presentation/format/webhooks/index.js +2 -0
- package/dist/presentation/format/webhooks/index.js.map +1 -0
- package/dist/presentation/format/webhooks/webhooks.js +59 -0
- package/dist/presentation/format/webhooks/webhooks.js.map +1 -0
- package/dist/presentation/ipc/client/address.js +8 -0
- package/dist/presentation/ipc/client/address.js.map +1 -0
- package/dist/presentation/ipc/client/client.js +23 -6
- package/dist/presentation/ipc/client/client.js.map +1 -1
- package/dist/presentation/ipc/client/index.js +1 -0
- package/dist/presentation/ipc/client/index.js.map +1 -1
- package/dist/presentation/ipc/client/remote.js +85 -0
- package/dist/presentation/ipc/client/remote.js.map +1 -0
- package/dist/presentation/ipc/contract/access/access.js +21 -0
- package/dist/presentation/ipc/contract/access/access.js.map +1 -0
- package/dist/presentation/ipc/contract/access/index.js +2 -0
- package/dist/presentation/ipc/contract/access/index.js.map +1 -0
- package/dist/presentation/ipc/contract/envelope.js +90 -6
- package/dist/presentation/ipc/contract/envelope.js.map +1 -1
- package/dist/presentation/ipc/contract/identity/audit.js +21 -0
- package/dist/presentation/ipc/contract/identity/audit.js.map +1 -0
- package/dist/presentation/ipc/contract/identity/identity.js +120 -0
- package/dist/presentation/ipc/contract/identity/identity.js.map +1 -0
- package/dist/presentation/ipc/contract/identity/index.js +3 -0
- package/dist/presentation/ipc/contract/identity/index.js.map +1 -0
- package/dist/presentation/ipc/contract/index.js +6 -0
- package/dist/presentation/ipc/contract/index.js.map +1 -1
- package/dist/presentation/ipc/contract/integrations/integrations.js +85 -0
- package/dist/presentation/ipc/contract/integrations/integrations.js.map +1 -0
- package/dist/presentation/ipc/contract/integrations/remote.js +16 -0
- package/dist/presentation/ipc/contract/integrations/remote.js.map +1 -0
- package/dist/presentation/ipc/contract/notifications/notifications.js +44 -0
- package/dist/presentation/ipc/contract/notifications/notifications.js.map +1 -0
- package/dist/presentation/ipc/contract/notifications/webhooks.js +48 -0
- package/dist/presentation/ipc/contract/notifications/webhooks.js.map +1 -0
- package/dist/presentation/ipc/contract/panel.js +5 -1
- package/dist/presentation/ipc/contract/panel.js.map +1 -1
- package/dist/presentation/ipc/contract/queue.js +46 -5
- package/dist/presentation/ipc/contract/queue.js.map +1 -1
- package/dist/presentation/ipc/contract/repositories.js +4 -0
- package/dist/presentation/ipc/contract/repositories.js.map +1 -1
- package/dist/presentation/ipc/contract/responses/stats.js +3 -0
- package/dist/presentation/ipc/contract/responses/stats.js.map +1 -1
- package/dist/presentation/ipc/contract/runs.js +12 -2
- package/dist/presentation/ipc/contract/runs.js.map +1 -1
- package/dist/presentation/ipc/contract/stats/stats.js +2 -0
- package/dist/presentation/ipc/contract/stats/stats.js.map +1 -1
- package/dist/presentation/ipc/handlers/access/access.js +74 -0
- package/dist/presentation/ipc/handlers/access/access.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/author.js +25 -0
- package/dist/presentation/ipc/handlers/access/author.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/guard.js +57 -0
- package/dist/presentation/ipc/handlers/access/guard.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/index.js +5 -0
- package/dist/presentation/ipc/handlers/access/index.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/method-actions.js +13 -0
- package/dist/presentation/ipc/handlers/access/method-actions.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/method-runs.js +76 -0
- package/dist/presentation/ipc/handlers/access/method-runs.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/method-settings.js +120 -0
- package/dist/presentation/ipc/handlers/access/method-settings.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/resource.js +129 -0
- package/dist/presentation/ipc/handlers/access/resource.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/visible.js +13 -0
- package/dist/presentation/ipc/handlers/access/visible.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-account-actions.js +52 -0
- package/dist/presentation/ipc/handlers/audit/audit-account-actions.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-actions.js +220 -0
- package/dist/presentation/ipc/handlers/audit/audit-actions.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-helpers.js +56 -0
- package/dist/presentation/ipc/handlers/audit/audit-helpers.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-list.js +57 -0
- package/dist/presentation/ipc/handlers/audit/audit-list.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-readers.js +74 -0
- package/dist/presentation/ipc/handlers/audit/audit-readers.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-settings-actions.js +73 -0
- package/dist/presentation/ipc/handlers/audit/audit-settings-actions.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-table.js +10 -0
- package/dist/presentation/ipc/handlers/audit/audit-table.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit.js +101 -0
- package/dist/presentation/ipc/handlers/audit/audit.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/index.js +5 -0
- package/dist/presentation/ipc/handlers/audit/index.js.map +1 -0
- package/dist/presentation/ipc/handlers/identity/identity.js +182 -0
- package/dist/presentation/ipc/handlers/identity/identity.js.map +1 -0
- package/dist/presentation/ipc/handlers/identity/index.js +2 -0
- package/dist/presentation/ipc/handlers/identity/index.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/index.js +6 -0
- package/dist/presentation/ipc/handlers/integrations/index.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/integrations.js +114 -0
- package/dist/presentation/ipc/handlers/integrations/integrations.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/notifications.js +49 -0
- package/dist/presentation/ipc/handlers/integrations/notifications.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/remote.js +35 -0
- package/dist/presentation/ipc/handlers/integrations/remote.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/skills.js +18 -0
- package/dist/presentation/ipc/handlers/integrations/skills.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/webhooks.js +30 -0
- package/dist/presentation/ipc/handlers/integrations/webhooks.js.map +1 -0
- package/dist/presentation/ipc/handlers/observers.js +10 -2
- package/dist/presentation/ipc/handlers/observers.js.map +1 -1
- package/dist/presentation/ipc/handlers/providers.js +9 -1
- package/dist/presentation/ipc/handlers/providers.js.map +1 -1
- package/dist/presentation/ipc/handlers/queue.js +70 -18
- package/dist/presentation/ipc/handlers/queue.js.map +1 -1
- package/dist/presentation/ipc/handlers/repositories.js +28 -13
- package/dist/presentation/ipc/handlers/repositories.js.map +1 -1
- package/dist/presentation/ipc/handlers/runs.js +13 -5
- package/dist/presentation/ipc/handlers/runs.js.map +1 -1
- package/dist/presentation/ipc/handlers/stats.js +27 -6
- package/dist/presentation/ipc/handlers/stats.js.map +1 -1
- package/dist/presentation/ipc/handlers/system.js +8 -1
- package/dist/presentation/ipc/handlers/system.js.map +1 -1
- package/dist/presentation/ipc/handlers/table.js +18 -3
- package/dist/presentation/ipc/handlers/table.js.map +1 -1
- package/dist/presentation/ipc/log-signals.js +78 -0
- package/dist/presentation/ipc/log-signals.js.map +1 -0
- package/dist/presentation/ipc/publisher.js +20 -3
- package/dist/presentation/ipc/publisher.js.map +1 -1
- package/dist/presentation/ipc/server.js +58 -14
- package/dist/presentation/ipc/server.js.map +1 -1
- package/dist/presentation/ipc/snapshots.js +22 -3
- package/dist/presentation/ipc/snapshots.js.map +1 -1
- package/dist/presentation/ipc/views/index.js +2 -0
- package/dist/presentation/ipc/views/index.js.map +1 -1
- package/dist/presentation/ipc/views/notifications/notifications.js +7 -0
- package/dist/presentation/ipc/views/notifications/notifications.js.map +1 -0
- package/dist/presentation/ipc/views/notifications/webhooks.js +6 -0
- package/dist/presentation/ipc/views/notifications/webhooks.js.map +1 -0
- package/dist/presentation/ipc/views/queue.js +3 -0
- package/dist/presentation/ipc/views/queue.js.map +1 -1
- package/dist/presentation/ipc/views/runs.js +18 -7
- package/dist/presentation/ipc/views/runs.js.map +1 -1
- package/dist/presentation/ipc/views/stats.js +11 -3
- package/dist/presentation/ipc/views/stats.js.map +1 -1
- package/dist/presentation/mcp/host-kit.js +2 -1
- package/dist/presentation/mcp/host-kit.js.map +1 -1
- package/dist/presentation/mcp/host-queue.js +19 -13
- package/dist/presentation/mcp/host-queue.js.map +1 -1
- package/dist/presentation/mcp/host-runs.js +10 -14
- package/dist/presentation/mcp/host-runs.js.map +1 -1
- package/dist/presentation/mcp/index.js +1 -0
- package/dist/presentation/mcp/index.js.map +1 -1
- package/dist/presentation/mcp/remote-bridge.js +50 -0
- package/dist/presentation/mcp/remote-bridge.js.map +1 -0
- package/dist/presentation/mcp/tools.js +18 -0
- package/dist/presentation/mcp/tools.js.map +1 -1
- package/dist/presentation/mcp/worker-extra.js +77 -5
- package/dist/presentation/mcp/worker-extra.js.map +1 -1
- package/dist/presentation/mcp/worker-tools.js.map +1 -1
- package/dist/presentation/mcp/worker.js +2 -1
- package/dist/presentation/mcp/worker.js.map +1 -1
- package/dist/presentation/web/access.js +42 -0
- package/dist/presentation/web/access.js.map +1 -0
- package/dist/presentation/web/auth/context.js +3 -0
- package/dist/presentation/web/auth/context.js.map +1 -0
- package/dist/presentation/web/auth/gate.js +33 -0
- package/dist/presentation/web/auth/gate.js.map +1 -0
- package/dist/presentation/web/auth/oidc.js +49 -0
- package/dist/presentation/web/auth/oidc.js.map +1 -0
- package/dist/presentation/web/auth/pages.js +43 -0
- package/dist/presentation/web/auth/pages.js.map +1 -0
- package/dist/presentation/web/auth/proxy.js +54 -0
- package/dist/presentation/web/auth/proxy.js.map +1 -0
- package/dist/presentation/web/auth/routes.js +152 -0
- package/dist/presentation/web/auth/routes.js.map +1 -0
- package/dist/presentation/web/auth/saml.js +65 -0
- package/dist/presentation/web/auth/saml.js.map +1 -0
- package/dist/presentation/web/auth/session.js +53 -0
- package/dist/presentation/web/auth/session.js.map +1 -0
- package/dist/presentation/web/errors.js +18 -1
- package/dist/presentation/web/errors.js.map +1 -1
- package/dist/presentation/web/hub.js +101 -22
- package/dist/presentation/web/hub.js.map +1 -1
- package/dist/presentation/web/live/protocol.js +68 -0
- package/dist/presentation/web/live/protocol.js.map +1 -0
- package/dist/presentation/web/live/read.js +29 -0
- package/dist/presentation/web/live/read.js.map +1 -0
- package/dist/presentation/web/live/socket.js +93 -0
- package/dist/presentation/web/live/socket.js.map +1 -0
- package/dist/presentation/web/live/state-topics.js +127 -0
- package/dist/presentation/web/live/state-topics.js.map +1 -0
- package/dist/presentation/web/live/topics.js +119 -0
- package/dist/presentation/web/live/topics.js.map +1 -0
- package/dist/presentation/web/options.js.map +1 -1
- package/dist/presentation/web/panel/daemon-panel.js +24 -4
- package/dist/presentation/web/panel/daemon-panel.js.map +1 -1
- package/dist/presentation/web/request.js +42 -3
- package/dist/presentation/web/request.js.map +1 -1
- package/dist/presentation/web/routes/access/access.js +14 -0
- package/dist/presentation/web/routes/access/access.js.map +1 -0
- package/dist/presentation/web/routes/audit/audit.js +11 -0
- package/dist/presentation/web/routes/audit/audit.js.map +1 -0
- package/dist/presentation/web/routes/integrations/integrations.js +147 -0
- package/dist/presentation/web/routes/integrations/integrations.js.map +1 -0
- package/dist/presentation/web/routes/integrations/webhooks.js +73 -0
- package/dist/presentation/web/routes/integrations/webhooks.js.map +1 -0
- package/dist/presentation/web/routes/queue.js +1 -1
- package/dist/presentation/web/routes/queue.js.map +1 -1
- package/dist/presentation/web/routes/runs.js +5 -1
- package/dist/presentation/web/routes/runs.js.map +1 -1
- package/dist/presentation/web/routes/system.js +21 -13
- package/dist/presentation/web/routes/system.js.map +1 -1
- package/dist/presentation/web/server.js +95 -17
- package/dist/presentation/web/server.js.map +1 -1
- package/dist/presentation/web/visible.js +93 -0
- package/dist/presentation/web/visible.js.map +1 -0
- package/dist/web/assets/EntryList-CMEscRod.js +3 -0
- package/dist/web/assets/FilterField-BQc_UwWN.js +7 -0
- package/dist/web/assets/LinkTabs-v8NyjDyU.js +4 -0
- package/dist/web/assets/SharedPipelinesGroup-BzlZ5U2Y.js +1 -0
- package/dist/web/assets/deliveryModes-CHEVNJxR.js +1 -0
- package/dist/web/assets/empty-Bho47NOE.js +41 -0
- package/dist/web/assets/index-vRNf1iRZ.css +2 -0
- package/dist/web/assets/index-ztjIJ-Ig.js +41 -0
- package/dist/web/assets/locales-BTrmAl7v.js +1 -0
- package/dist/web/assets/pipelines-DVZ7cqyZ.js +14 -0
- package/dist/web/assets/settingFields-iGwxRKJI.js +1 -0
- package/dist/web/assets/settings-DN_KmJBg.js +6 -0
- package/dist/web/assets/stats-4iy1ZRny.js +1 -0
- package/dist/web/assets/tabs-D26rwwNs.js +1 -0
- package/dist/web/assets/toggle-group-D-oIoacR.js +1 -0
- package/dist/web/assets/topology-CaSfGJbk.js +1 -0
- package/dist/web/index.html +10 -10
- package/integrations/claude-code/.claude-plugin/plugin.json +1 -1
- package/package.json +12 -4
- package/dist/web/assets/EntryList-Cyc9PxYQ.js +0 -3
- package/dist/web/assets/FilterField-DOat7bHi.js +0 -7
- package/dist/web/assets/LinkTabs-V5hVhmkv.js +0 -4
- package/dist/web/assets/SharedPipelinesGroup-CMV55Qri.js +0 -1
- package/dist/web/assets/card-DDDwEBup.js +0 -1
- package/dist/web/assets/deliveryModes-OVH1wAmC.js +0 -1
- package/dist/web/assets/empty-CF7EgKd2.js +0 -41
- package/dist/web/assets/index-7lFvzi1k.js +0 -41
- package/dist/web/assets/index-BJYNhfGR.css +0 -2
- package/dist/web/assets/locales-3BQ5tRcZ.js +0 -1
- package/dist/web/assets/pipelines-BLhOZXCy.js +0 -14
- package/dist/web/assets/settingFields-C8-XJpPl.js +0 -1
- package/dist/web/assets/settings-96DThDqz.js +0 -6
- package/dist/web/assets/stats-B1imf_Vj.js +0 -1
- package/dist/web/assets/tabs-DyEM16mP.js +0 -1
- package/dist/web/assets/topology-Dyq425Mw.js +0 -1
|
@@ -2,8 +2,8 @@ import { isAbsolute } from 'node:path';
|
|
|
2
2
|
import { addError, join, readBoolean, readEntries, readMapping, readString, readStrings, } from '../validate-context.js';
|
|
3
3
|
import { checkEnvironment } from '../validate-runtimes.js';
|
|
4
4
|
import { parseReferences } from '../../types/mcp/reference.js';
|
|
5
|
-
import {} from '../../types/specialist.js';
|
|
6
|
-
const MCP_SERVER_KEYS = ['command', 'args', 'env'];
|
|
5
|
+
import { CONNECTION_NAME, } from '../../types/specialist.js';
|
|
6
|
+
const MCP_SERVER_KEYS = ['command', 'args', 'env', 'connection'];
|
|
7
7
|
const MCP_SERVER_NAME = /^[A-Za-z0-9_-]+$/;
|
|
8
8
|
const RESERVED_MCP_SERVER = 'aip';
|
|
9
9
|
/** Reports a broken `${…}` reference in a value of an MCP server. */
|
|
@@ -61,12 +61,35 @@ function checkMcpServer(ctx, value, path, allowed) {
|
|
|
61
61
|
server.args = readStrings(ctx, field, fieldPath);
|
|
62
62
|
if (key === 'env')
|
|
63
63
|
server.env = checkEnvironment(ctx, field, fieldPath);
|
|
64
|
+
if (key === 'connection') {
|
|
65
|
+
const name = readString(ctx, field, fieldPath);
|
|
66
|
+
if (name === null)
|
|
67
|
+
continue;
|
|
68
|
+
// the name is never expanded: a `${…}` fails the pattern like any other wrong character
|
|
69
|
+
if (CONNECTION_NAME.test(name))
|
|
70
|
+
server.connection = name;
|
|
71
|
+
else
|
|
72
|
+
addError(ctx, fieldPath, 'must be the name of a connection: lowercase letters, digits, ".", "-" and "_"');
|
|
73
|
+
}
|
|
64
74
|
}
|
|
65
|
-
|
|
66
|
-
addError(ctx, join(path, 'command'), 'is required');
|
|
75
|
+
checkTransport(ctx, mapping, path);
|
|
67
76
|
checkReferences(ctx, server, path);
|
|
68
77
|
return server;
|
|
69
78
|
}
|
|
79
|
+
/** Exactly one of `command` and `connection`; `args` and `env` belong to a started program only. */
|
|
80
|
+
function checkTransport(ctx, mapping, path) {
|
|
81
|
+
const hasCommand = 'command' in mapping;
|
|
82
|
+
const hasConnection = 'connection' in mapping;
|
|
83
|
+
if (hasCommand === hasConnection) {
|
|
84
|
+
addError(ctx, path, 'exactly one of the keys `command` and `connection` is required');
|
|
85
|
+
}
|
|
86
|
+
if (!hasConnection)
|
|
87
|
+
return;
|
|
88
|
+
for (const key of ['args', 'env']) {
|
|
89
|
+
if (key in mapping)
|
|
90
|
+
addError(ctx, join(path, key), 'is not allowed together with `connection`');
|
|
91
|
+
}
|
|
92
|
+
}
|
|
70
93
|
/** Checks `swarm.mcp_servers`: the servers by name with the flag `all_specialists`. */
|
|
71
94
|
export function checkMcpCatalog(ctx, value) {
|
|
72
95
|
const catalog = {};
|
|
@@ -96,7 +119,12 @@ export function checkMcpCatalog(ctx, value) {
|
|
|
96
119
|
return catalog;
|
|
97
120
|
}
|
|
98
121
|
function plain(server) {
|
|
99
|
-
return {
|
|
122
|
+
return {
|
|
123
|
+
command: server.command,
|
|
124
|
+
args: [...server.args],
|
|
125
|
+
env: { ...server.env },
|
|
126
|
+
...(server.connection === undefined ? {} : { connection: server.connection }),
|
|
127
|
+
};
|
|
100
128
|
}
|
|
101
129
|
/**
|
|
102
130
|
* Gives every specialist its final set of servers: the catalog servers for all specialists, the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mcp-servers.js","sourceRoot":"","sources":["../../../../../src/feature/swarm-config/services/sections/mcp-servers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AACvC,OAAO,EAEL,QAAQ,EACR,IAAI,EACJ,WAAW,EACX,WAAW,EACX,WAAW,EACX,UAAU,EACV,WAAW,GACZ,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,
|
|
1
|
+
{"version":3,"file":"mcp-servers.js","sourceRoot":"","sources":["../../../../../src/feature/swarm-config/services/sections/mcp-servers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AACvC,OAAO,EAEL,QAAQ,EACR,IAAI,EACJ,WAAW,EACX,WAAW,EACX,WAAW,EACX,UAAU,EACV,WAAW,GACZ,MAAM,wBAAwB,CAAC;AAChC,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAC/D,OAAO,EACL,eAAe,GAIhB,MAAM,2BAA2B,CAAC;AAEnC,MAAM,eAAe,GAAG,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,EAAE,YAAY,CAAC,CAAC;AAEjE,MAAM,eAAe,GAAG,kBAAkB,CAAC;AAE3C,MAAM,mBAAmB,GAAG,KAAK,CAAC;AAElC,qEAAqE;AACrE,SAAS,cAAc,CAAC,GAAoB,EAAE,KAAa,EAA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,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;gBACnC,MAAM,IAAI,GAAG,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,YAAY,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,wBAAwB,CAAC;gBAC1F,QAAQ,CAAC,GAAG,EAAE,IAAI,EAAE,wBAAwB,IAAI,KAAK,IAAI,EAAE,CAAC,CAAC;YAC/D,CAAC;QACH,CAAC,CAAC,CAAC;QACH,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAE,UAAU,CAAC,GAAG,CAAC,CAAC;QACxC,IAAI,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC,MAAM,GAAG,CAAC;YAAE,UAAU,CAAC,GAAG,GAAG,QAAQ,CAAC;IAClE,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { textFileProblem } from '../../../../platform/files/index.js';
|
|
2
|
+
import { addError, join, readBoolean, readEntries, readMapping, readString, readStrings, } from '../validate-context.js';
|
|
3
|
+
const SAML_KEYS = [
|
|
4
|
+
'idp_metadata',
|
|
5
|
+
'entity_id',
|
|
6
|
+
'key_file',
|
|
7
|
+
'cert_file',
|
|
8
|
+
'label',
|
|
9
|
+
'claims',
|
|
10
|
+
'attributes',
|
|
11
|
+
'trust_email',
|
|
12
|
+
'allowed_domains',
|
|
13
|
+
];
|
|
14
|
+
const DOMAIN = /^[a-z0-9]([a-z0-9-]*[a-z0-9])?(\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)+$/i;
|
|
15
|
+
/** Whether the metadata setting is a URL (else it is a path of a file). */
|
|
16
|
+
export function isMetadataUrl(value) {
|
|
17
|
+
return /^https?:\/\//i.test(value);
|
|
18
|
+
}
|
|
19
|
+
function checkFile(ctx, value, path) {
|
|
20
|
+
if (value === null)
|
|
21
|
+
return null;
|
|
22
|
+
const problem = textFileProblem(value);
|
|
23
|
+
if (problem !== null) {
|
|
24
|
+
addError(ctx, path, problem);
|
|
25
|
+
return null;
|
|
26
|
+
}
|
|
27
|
+
return value;
|
|
28
|
+
}
|
|
29
|
+
function checkMetadata(ctx, value, path) {
|
|
30
|
+
const text = readString(ctx, value, path);
|
|
31
|
+
if (text === null)
|
|
32
|
+
return null;
|
|
33
|
+
if (!isMetadataUrl(text))
|
|
34
|
+
return checkFile(ctx, text, path);
|
|
35
|
+
try {
|
|
36
|
+
new URL(text);
|
|
37
|
+
return text;
|
|
38
|
+
}
|
|
39
|
+
catch {
|
|
40
|
+
addError(ctx, path, 'must be a URL or the path of a file');
|
|
41
|
+
return null;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
function checkClaims(ctx, value, path, saml) {
|
|
45
|
+
const mapping = readMapping(ctx, value, path);
|
|
46
|
+
if (!mapping)
|
|
47
|
+
return;
|
|
48
|
+
for (const [key, field] of readEntries(ctx, mapping, path, ['email', 'name'])) {
|
|
49
|
+
const text = readString(ctx, field, join(path, key));
|
|
50
|
+
if (text !== null)
|
|
51
|
+
saml.claims[key] = text;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
function checkAttributes(ctx, value, path, saml) {
|
|
55
|
+
const mapping = readMapping(ctx, value, path);
|
|
56
|
+
if (!mapping)
|
|
57
|
+
return;
|
|
58
|
+
for (const [key, field] of readEntries(ctx, mapping, path, null)) {
|
|
59
|
+
const text = readString(ctx, field, join(path, key));
|
|
60
|
+
if (text !== null)
|
|
61
|
+
saml.attributes[key] = text;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
function checkField(ctx, saml, key, field, path) {
|
|
65
|
+
if (key === 'idp_metadata')
|
|
66
|
+
saml.idpMetadata = checkMetadata(ctx, field, path) ?? '';
|
|
67
|
+
if (key === 'entity_id')
|
|
68
|
+
saml.entityId = readString(ctx, field, path);
|
|
69
|
+
if (key === 'key_file')
|
|
70
|
+
saml.keyFile = checkFile(ctx, readString(ctx, field, path), path) ?? '';
|
|
71
|
+
if (key === 'cert_file')
|
|
72
|
+
saml.certFile = checkFile(ctx, readString(ctx, field, path), path) ?? '';
|
|
73
|
+
if (key === 'label')
|
|
74
|
+
saml.label = readString(ctx, field, path) ?? saml.label;
|
|
75
|
+
if (key === 'claims')
|
|
76
|
+
checkClaims(ctx, field, path, saml);
|
|
77
|
+
if (key === 'attributes')
|
|
78
|
+
checkAttributes(ctx, field, path, saml);
|
|
79
|
+
if (key === 'trust_email')
|
|
80
|
+
saml.trustEmail = readBoolean(ctx, field, path) ?? saml.trustEmail;
|
|
81
|
+
if (key === 'allowed_domains') {
|
|
82
|
+
const items = readStrings(ctx, field, path);
|
|
83
|
+
items.forEach((item, index) => {
|
|
84
|
+
if (!DOMAIN.test(item))
|
|
85
|
+
addError(ctx, `${path}[${index}]`, 'must be a domain such as corp.com');
|
|
86
|
+
});
|
|
87
|
+
saml.allowedDomains = items.filter((item) => DOMAIN.test(item)).map((d) => d.toLowerCase());
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
/** Checks `swarm.server.sso.saml`; `null` while there are errors. The key and the certificate are files, never inline. */
|
|
91
|
+
export function checkSaml(ctx, value, path) {
|
|
92
|
+
const mapping = readMapping(ctx, value, path);
|
|
93
|
+
if (!mapping)
|
|
94
|
+
return null;
|
|
95
|
+
const saml = {
|
|
96
|
+
idpMetadata: '',
|
|
97
|
+
entityId: null,
|
|
98
|
+
keyFile: '',
|
|
99
|
+
certFile: '',
|
|
100
|
+
label: 'SAML',
|
|
101
|
+
claims: { email: null, name: null },
|
|
102
|
+
attributes: {},
|
|
103
|
+
trustEmail: false,
|
|
104
|
+
allowedDomains: [],
|
|
105
|
+
};
|
|
106
|
+
const before = ctx.errors.length;
|
|
107
|
+
for (const [key, field] of readEntries(ctx, mapping, path, SAML_KEYS)) {
|
|
108
|
+
checkField(ctx, saml, key, field, join(path, key));
|
|
109
|
+
}
|
|
110
|
+
for (const required of ['idp_metadata', 'key_file', 'cert_file']) {
|
|
111
|
+
if (!(required in mapping))
|
|
112
|
+
addError(ctx, join(path, required), 'is required');
|
|
113
|
+
}
|
|
114
|
+
return ctx.errors.length === before ? saml : null;
|
|
115
|
+
}
|
|
116
|
+
//# sourceMappingURL=server-saml.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"server-saml.js","sourceRoot":"","sources":["../../../../../src/feature/swarm-config/services/sections/server-saml.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,qCAAqC,CAAC;AAEtE,OAAO,EAEL,QAAQ,EACR,IAAI,EACJ,WAAW,EACX,WAAW,EACX,WAAW,EACX,UAAU,EACV,WAAW,GACZ,MAAM,wBAAwB,CAAC;AAEhC,MAAM,SAAS,GAAG;IAChB,cAAc;IACd,WAAW;IACX,UAAU;IACV,WAAW;IACX,OAAO;IACP,QAAQ;IACR,YAAY;IACZ,aAAa;IACb,iBAAiB;CAClB,CAAC;AAEF,MAAM,MAAM,GAAG,oEAAoE,CAAC;AAEpF,2EAA2E;AAC3E,MAAM,UAAU,aAAa,CAAC,KAAa;IACzC,OAAO,eAAe,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;AACrC,CAAC;AAED,SAAS,SAAS,CAAC,GAAoB,EAAE,KAAoB,EAAE,IAAY;IACzE,IAAI,KAAK,KAAK,IAAI;QAAE,OAAO,IAAI,CAAC;IAChC,MAAM,OAAO,GAAG,eAAe,CAAC,KAAK,CAAC,CAAC;IACvC,IAAI,OAAO,KAAK,IAAI,EAAE,CAAC;QACrB,QAAQ,CAAC,GAAG,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;QAC7B,OAAO,IAAI,CAAC;IACd,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC;AAED,SAAS,aAAa,CAAC,GAAoB,EAAE,KAAc,EAAE,IAAY;IACvE,MAAM,IAAI,GAAG,UAAU,CAAC,GAAG,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC;IAC1C,IAAI,IAAI,KAAK,IAAI;QAA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AM,GAAG,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC;IACjC,KAAK,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,WAAW,CAAC,GAAG,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,CAAC,EAAE,CAAC;QACtE,UAAU,CAAC,GAAG,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,EAAE,IAAI,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC,CAAC;IACrD,CAAC;IACD,KAAK,MAAM,QAAQ,IAAI,CAAC,cAAc,EAAE,UAAU,EAAE,WAAW,CAAC,EAAE,CAAC;QACjE,IAAI,CAAC,CAAC,QAAQ,IAAI,OAAO,CAAC;YAAE,QAAQ,CAAC,GAAG,EAAE,IAAI,CAAC,IAAI,EAAE,QAAQ,CAAC,EAAE,aAAa,CAAC,CAAC;IACjF,CAAC;IACD,OAAO,GAAG,CAAC,MAAM,CAAC,MAAM,KAAK,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC;AACpD,CAAC"}
|
|
@@ -0,0 +1,272 @@
|
|
|
1
|
+
import { isIP } from 'node:net';
|
|
2
|
+
import { addError, join, readBoolean, readEntries, readMapping, readString, readStrings, } from '../validate-context.js';
|
|
3
|
+
import { checkSaml } from './server-saml.js';
|
|
4
|
+
import {} from '../../types/errors.js';
|
|
5
|
+
import { ACCESS_ROLES, isAccessRole } from '../../types/access/index.js';
|
|
6
|
+
import { DEFAULT_OIDC_SCOPES, defaultServer, } from '../../types/settings.js';
|
|
7
|
+
const SERVER_KEYS = [
|
|
8
|
+
'enabled',
|
|
9
|
+
'listen',
|
|
10
|
+
'public_url',
|
|
11
|
+
'trusted_proxies',
|
|
12
|
+
'session_ttl',
|
|
13
|
+
'token_max_ttl',
|
|
14
|
+
'sso',
|
|
15
|
+
'audit_retention',
|
|
16
|
+
'commit_trailer',
|
|
17
|
+
'default_role',
|
|
18
|
+
];
|
|
19
|
+
const SSO_KEYS = ['oidc', 'saml'];
|
|
20
|
+
const OIDC_KEYS = [
|
|
21
|
+
'issuer',
|
|
22
|
+
'client_id',
|
|
23
|
+
'client_secret_env',
|
|
24
|
+
'scopes',
|
|
25
|
+
'label',
|
|
26
|
+
'claims',
|
|
27
|
+
'attributes',
|
|
28
|
+
'allowed_domains',
|
|
29
|
+
];
|
|
30
|
+
const ENV_NAME = /^[A-Za-z_][A-Za-z0-9_]*$/;
|
|
31
|
+
const DOMAIN = /^[a-z0-9]([a-z0-9-]*[a-z0-9])?(\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)+$/i;
|
|
32
|
+
function issuerProblem(value) {
|
|
33
|
+
let url;
|
|
34
|
+
try {
|
|
35
|
+
url = new URL(value);
|
|
36
|
+
}
|
|
37
|
+
catch {
|
|
38
|
+
return 'must be a URL such as `https://sso.example.com/realms/aip`';
|
|
39
|
+
}
|
|
40
|
+
if (url.protocol !== 'http:' && url.protocol !== 'https:')
|
|
41
|
+
return 'must use http or https';
|
|
42
|
+
if (url.search !== '' || url.hash !== '')
|
|
43
|
+
return 'must have no query or fragment';
|
|
44
|
+
return null;
|
|
45
|
+
}
|
|
46
|
+
function checkClaims(ctx, value, path, oidc) {
|
|
47
|
+
const mapping = readMapping(ctx, value, path);
|
|
48
|
+
if (!mapping)
|
|
49
|
+
return;
|
|
50
|
+
for (const [key, field] of readEntries(ctx, mapping, path, ['email', 'name'])) {
|
|
51
|
+
const text = readString(ctx, field, join(path, key));
|
|
52
|
+
if (text !== null)
|
|
53
|
+
oidc.claims[key] = text;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
function checkAttributes(ctx, value, path, oidc) {
|
|
57
|
+
const mapping = readMapping(ctx, value, path);
|
|
58
|
+
if (!mapping)
|
|
59
|
+
return;
|
|
60
|
+
for (const [key, field] of readEntries(ctx, mapping, path, null)) {
|
|
61
|
+
const text = readString(ctx, field, join(path, key));
|
|
62
|
+
if (text !== null)
|
|
63
|
+
oidc.attributes[key] = text;
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
function checkOidcField(ctx, oidc, key, field, path) {
|
|
67
|
+
if (key === 'issuer') {
|
|
68
|
+
const value = readString(ctx, field, path);
|
|
69
|
+
const problem = value === null ? null : issuerProblem(value);
|
|
70
|
+
if (problem)
|
|
71
|
+
addError(ctx, path, problem);
|
|
72
|
+
else if (value !== null)
|
|
73
|
+
oidc.issuer = value;
|
|
74
|
+
}
|
|
75
|
+
if (key === 'client_id')
|
|
76
|
+
oidc.clientId = readString(ctx, field, path) ?? oidc.clientId;
|
|
77
|
+
if (key === 'client_secret_env') {
|
|
78
|
+
const value = readString(ctx, field, path);
|
|
79
|
+
if (value !== null && !ENV_NAME.test(value)) {
|
|
80
|
+
addError(ctx, path, 'must be the name of an environment variable');
|
|
81
|
+
}
|
|
82
|
+
else if (value !== null)
|
|
83
|
+
oidc.clientSecretEnv = value;
|
|
84
|
+
}
|
|
85
|
+
if (key === 'scopes') {
|
|
86
|
+
const items = readStrings(ctx, field, path);
|
|
87
|
+
if (items.length > 0)
|
|
88
|
+
oidc.scopes = items;
|
|
89
|
+
}
|
|
90
|
+
if (key === 'label')
|
|
91
|
+
oidc.label = readString(ctx, field, path) ?? oidc.label;
|
|
92
|
+
if (key === 'claims')
|
|
93
|
+
checkClaims(ctx, field, path, oidc);
|
|
94
|
+
if (key === 'attributes')
|
|
95
|
+
checkAttributes(ctx, field, path, oidc);
|
|
96
|
+
if (key === 'allowed_domains') {
|
|
97
|
+
const items = readStrings(ctx, field, path);
|
|
98
|
+
items.forEach((item, index) => {
|
|
99
|
+
if (!DOMAIN.test(item))
|
|
100
|
+
addError(ctx, `${path}[${index}]`, 'must be a domain such as corp.com');
|
|
101
|
+
});
|
|
102
|
+
oidc.allowedDomains = items.filter((item) => DOMAIN.test(item)).map((d) => d.toLowerCase());
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
function checkOidc(ctx, value, path) {
|
|
106
|
+
const mapping = readMapping(ctx, value, path);
|
|
107
|
+
if (!mapping)
|
|
108
|
+
return null;
|
|
109
|
+
const oidc = {
|
|
110
|
+
issuer: '',
|
|
111
|
+
clientId: '',
|
|
112
|
+
clientSecretEnv: '',
|
|
113
|
+
scopes: [...DEFAULT_OIDC_SCOPES],
|
|
114
|
+
label: 'SSO',
|
|
115
|
+
claims: { email: 'email', name: 'name' },
|
|
116
|
+
attributes: {},
|
|
117
|
+
allowedDomains: [],
|
|
118
|
+
};
|
|
119
|
+
if ('client_secret' in mapping) {
|
|
120
|
+
addError(ctx, join(path, 'client_secret'), 'the client secret must not be stored in settings.yaml; set `client_secret_env` to the name of an environment variable of the daemon');
|
|
121
|
+
}
|
|
122
|
+
const keys = [...OIDC_KEYS, 'client_secret'];
|
|
123
|
+
const before = ctx.errors.length;
|
|
124
|
+
for (const [key, field] of readEntries(ctx, mapping, path, keys)) {
|
|
125
|
+
if (key !== 'client_secret')
|
|
126
|
+
checkOidcField(ctx, oidc, key, field, join(path, key));
|
|
127
|
+
}
|
|
128
|
+
for (const required of ['issuer', 'client_id', 'client_secret_env']) {
|
|
129
|
+
if (!(required in mapping))
|
|
130
|
+
addError(ctx, join(path, required), 'is required');
|
|
131
|
+
}
|
|
132
|
+
return ctx.errors.length === before ? oidc : null;
|
|
133
|
+
}
|
|
134
|
+
function checkSso(ctx, value, server) {
|
|
135
|
+
const path = 'swarm.server.sso';
|
|
136
|
+
const mapping = readMapping(ctx, value, path);
|
|
137
|
+
if (!mapping)
|
|
138
|
+
return;
|
|
139
|
+
for (const [key, field] of readEntries(ctx, mapping, path, SSO_KEYS)) {
|
|
140
|
+
if (key === 'oidc')
|
|
141
|
+
server.sso.oidc = checkOidc(ctx, field, join(path, key));
|
|
142
|
+
if (key === 'saml')
|
|
143
|
+
server.sso.saml = checkSaml(ctx, field, join(path, key));
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
const SESSION_TTL = /^[1-9]\d*[hd]$/;
|
|
147
|
+
const TOKEN_TTL = /^[1-9]\d*d$/;
|
|
148
|
+
const AUDIT_RETENTION = /^[1-9]\d*d$/;
|
|
149
|
+
/** `Name <email>`: a name without angle brackets, then an address in them. */
|
|
150
|
+
const TRAILER = /^[^<>\r\n]+ <[^<>\s@]+@[^<>\s@]+>$/;
|
|
151
|
+
function listenProblem(value) {
|
|
152
|
+
const match = /^(.+):(\d{1,5})$/.exec(value);
|
|
153
|
+
const port = match ? Number(match[2]) : 0;
|
|
154
|
+
if (!match || port < 1 || port > 65535)
|
|
155
|
+
return 'must be `<address>:<port>`';
|
|
156
|
+
return null;
|
|
157
|
+
}
|
|
158
|
+
function publicUrlProblem(value) {
|
|
159
|
+
let url;
|
|
160
|
+
try {
|
|
161
|
+
url = new URL(value);
|
|
162
|
+
}
|
|
163
|
+
catch {
|
|
164
|
+
return 'must be a URL such as `https://aip.example.com`';
|
|
165
|
+
}
|
|
166
|
+
if (url.protocol !== 'http:' && url.protocol !== 'https:')
|
|
167
|
+
return 'must use http or https';
|
|
168
|
+
if (url.pathname !== '/' || url.search !== '' || url.hash !== '')
|
|
169
|
+
return 'must have no path';
|
|
170
|
+
return null;
|
|
171
|
+
}
|
|
172
|
+
function checkField(ctx, server, key, field, path) {
|
|
173
|
+
if (key === 'sso')
|
|
174
|
+
checkSso(ctx, field, server);
|
|
175
|
+
if (key === 'enabled')
|
|
176
|
+
server.enabled = readBoolean(ctx, field, path) ?? server.enabled;
|
|
177
|
+
if (key === 'listen') {
|
|
178
|
+
const value = readString(ctx, field, path);
|
|
179
|
+
const problem = value === null ? null : listenProblem(value);
|
|
180
|
+
if (problem)
|
|
181
|
+
addError(ctx, path, problem);
|
|
182
|
+
else if (value !== null)
|
|
183
|
+
server.listen = value;
|
|
184
|
+
}
|
|
185
|
+
if (key === 'public_url') {
|
|
186
|
+
const value = readString(ctx, field, path);
|
|
187
|
+
const problem = value === null ? null : publicUrlProblem(value);
|
|
188
|
+
if (problem)
|
|
189
|
+
addError(ctx, path, problem);
|
|
190
|
+
else if (value !== null)
|
|
191
|
+
server.publicUrl = value.replace(/\/$/, '');
|
|
192
|
+
}
|
|
193
|
+
if (key === 'trusted_proxies') {
|
|
194
|
+
const items = readStrings(ctx, field, path);
|
|
195
|
+
items.forEach((item, index) => {
|
|
196
|
+
if (isIP(item) === 0)
|
|
197
|
+
addError(ctx, `${path}[${index}]`, 'must be an IP address');
|
|
198
|
+
});
|
|
199
|
+
server.trustedProxies = items.filter((item) => isIP(item) !== 0);
|
|
200
|
+
}
|
|
201
|
+
if (key === 'session_ttl') {
|
|
202
|
+
const value = readString(ctx, field, path);
|
|
203
|
+
if (value !== null && !SESSION_TTL.test(value))
|
|
204
|
+
addError(ctx, path, 'must be `<n>h` or `<n>d`');
|
|
205
|
+
else if (value !== null)
|
|
206
|
+
server.sessionTtl = value;
|
|
207
|
+
}
|
|
208
|
+
if (key === 'token_max_ttl') {
|
|
209
|
+
const value = readString(ctx, field, path);
|
|
210
|
+
if (value !== null && !TOKEN_TTL.test(value))
|
|
211
|
+
addError(ctx, path, 'must be `<n>d`');
|
|
212
|
+
else if (value !== null)
|
|
213
|
+
server.tokenMaxTtl = value;
|
|
214
|
+
}
|
|
215
|
+
if (key === 'audit_retention') {
|
|
216
|
+
const value = readString(ctx, field, path);
|
|
217
|
+
if (value !== null && !AUDIT_RETENTION.test(value))
|
|
218
|
+
addError(ctx, path, 'must be `<n>d`');
|
|
219
|
+
else if (value !== null)
|
|
220
|
+
server.auditRetention = value;
|
|
221
|
+
}
|
|
222
|
+
if (key === 'commit_trailer') {
|
|
223
|
+
const value = readString(ctx, field, path)?.trim() ?? null;
|
|
224
|
+
if (value !== null && !TRAILER.test(value))
|
|
225
|
+
addError(ctx, path, 'must be `Name <email>`');
|
|
226
|
+
else if (value !== null)
|
|
227
|
+
server.commitTrailer = value;
|
|
228
|
+
}
|
|
229
|
+
if (key === 'default_role') {
|
|
230
|
+
const value = readString(ctx, field, path);
|
|
231
|
+
if (value !== null && !isAccessRole(value)) {
|
|
232
|
+
addError(ctx, path, `must be one of ${ACCESS_ROLES.join(', ')}`);
|
|
233
|
+
}
|
|
234
|
+
else if (value !== null)
|
|
235
|
+
server.defaultRole = value;
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
/** Checks `swarm.server`; fills `server` with the valid fields. */
|
|
239
|
+
export function checkServer(ctx, value, server) {
|
|
240
|
+
const mapping = readMapping(ctx, value, 'swarm.server');
|
|
241
|
+
if (!mapping)
|
|
242
|
+
return;
|
|
243
|
+
for (const [key, field] of readEntries(ctx, mapping, 'swarm.server', SERVER_KEYS)) {
|
|
244
|
+
checkField(ctx, server, key, field, join('swarm.server', key));
|
|
245
|
+
}
|
|
246
|
+
if (!server.enabled)
|
|
247
|
+
return;
|
|
248
|
+
if (server.publicUrl === null && !('public_url' in mapping)) {
|
|
249
|
+
addError(ctx, 'swarm.server.public_url', 'is required when server.enabled is true');
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
/** Server mode needs the panel and a login: the shared token and `autostart: false` conflict. */
|
|
253
|
+
export function checkServerWeb(ctx, server, web) {
|
|
254
|
+
if (!server.enabled)
|
|
255
|
+
return;
|
|
256
|
+
if (web.auth === 'none') {
|
|
257
|
+
addError(ctx, 'swarm.web.auth', 'must not be `none` when server.enabled is true');
|
|
258
|
+
}
|
|
259
|
+
if (!web.autostart) {
|
|
260
|
+
addError(ctx, 'swarm.web.autostart', 'must not be false when server.enabled is true');
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
/** Checks the `server` section alone together with `web`; `value` is the content of `swarm.server`. */
|
|
264
|
+
export function validateServerSection(value, web) {
|
|
265
|
+
const ctx = { errors: [] };
|
|
266
|
+
const server = defaultServer();
|
|
267
|
+
if (value !== undefined)
|
|
268
|
+
checkServer(ctx, value, server);
|
|
269
|
+
checkServerWeb(ctx, server, web);
|
|
270
|
+
return { server, errors: ctx.errors };
|
|
271
|
+
}
|
|
272
|
+
//# sourceMappingURL=server.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"server.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E,EAAE,CAAC;IAC5C,MAAM,MAAM,GAAG,aAAa,EAAE,CAAC;IAC/B,IAAI,KAAK,KAAK,SAAS;QAAE,WAAW,CAAC,GAAG,EAAE,KAAK,EAAE,MAAM,CAAC,CAAC;IACzD,cAAc,CAAC,GAAG,EAAE,MAAM,EAAE,GAAG,CAAC,CAAC;IACjC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,CAAC;AACxC,CAAC"}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { homedir } from 'node:os';
|
|
2
|
+
import { rejected } from '../../../platform/errors/index.js';
|
|
2
3
|
import { ConfigLoadError, pipelineNameOf, providerName, variantNameOf, } from '../types/index.js';
|
|
3
4
|
import { configPaths } from './discover.js';
|
|
4
|
-
import {
|
|
5
|
+
import { serverModeProblem } from './validate-settings.js';
|
|
6
|
+
import { loadAttachmentSettings, loadConfig, loadConfigSources, loadGlobalConfigSources, loadNetworkSettings, loadRuntimeSettings, loadQueueSettings, loadServerSettings, loadStatsSettings, } from './load.js';
|
|
5
7
|
/** The configuration files of the repositories, read from disk on every call. */
|
|
6
8
|
export class ConfigService {
|
|
7
9
|
environment;
|
|
@@ -95,6 +97,17 @@ export class ConfigService {
|
|
|
95
97
|
return `invalid swarm.stats: ${error.message}`;
|
|
96
98
|
}
|
|
97
99
|
}
|
|
100
|
+
/** Current `server` of the shared settings.yaml, or the text of the error in it. */
|
|
101
|
+
serverSettings() {
|
|
102
|
+
try {
|
|
103
|
+
return loadServerSettings(this.pathsOf('.'));
|
|
104
|
+
}
|
|
105
|
+
catch (error) {
|
|
106
|
+
if (!(error instanceof ConfigLoadError))
|
|
107
|
+
throw error;
|
|
108
|
+
return `invalid swarm.server: ${error.message}`;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
98
111
|
/** Current `queue` of the shared settings.yaml, or the text of the error in it. */
|
|
99
112
|
queueSettings() {
|
|
100
113
|
try {
|
|
@@ -107,4 +120,15 @@ export class ConfigService {
|
|
|
107
120
|
}
|
|
108
121
|
}
|
|
109
122
|
}
|
|
123
|
+
/** Whether the daemon works in the server mode; `false` when its settings do not load. */
|
|
124
|
+
export function serverModeOn(config) {
|
|
125
|
+
const settings = config.serverSettings();
|
|
126
|
+
return typeof settings !== 'string' && settings.enabled;
|
|
127
|
+
}
|
|
128
|
+
/** In the server mode a task or a delivery in `worktree` or `commit` is refused: only a branch is delivered. */
|
|
129
|
+
export function requireDeliveryMode(config, mode) {
|
|
130
|
+
if (mode === null || mode === undefined || mode === 'branch' || !serverModeOn(config))
|
|
131
|
+
return;
|
|
132
|
+
throw rejected(serverModeProblem(mode));
|
|
133
|
+
}
|
|
110
134
|
//# sourceMappingURL=settings.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"settings.js","sourceRoot":"","sources":["../../../../src/feature/swarm-config/services/settings.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAElC,OAAO,EACL,eAAe,EACf,cAAc,EACd,YAAY,EACZ,aAAa,
|
|
1
|
+
{"version":3,"file":"settings.js","sourceRoot":"","sources":["../../../../src/feature/swarm-config/services/settings.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAElC,OAAO,EAAE,QAAQ,EAAE,MAAM,mCAAmC,CAAC;AAE7D,OAAO,EACL,eAAe,EACf,cAAc,EACd,YAAY,EACZ,aAAa,GAWd,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EACL,sBAAsB,EACtB,UAAU,EACV,iBAAiB,EACjB,uBAAuB,EACvB,mBAAmB,EACnB,mBAAmB,EACnB,iBAAiB,EACjB,kBAAkB,EAClB,iBAAiB,GAClB,MAAM,WAAW,CAAC;AAanB,iFAAiF;AACjF,MAAM,O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