Files
cluster-map/openapi/config-values.yaml
T
Виталий ЧефановandClaude Opus 5.5 3cdc2583ee v0.8.0: problem badges, actions as the viewer, load, events, lock
Problems: cards, namespace and node boxes and the tree carry a yellow or
red badge, computed on the server from object state (crash loops, image
pulls, pending and unschedulable pods, readiness older than 2 minutes, a
stuck rollout, a failed CronJob run, Services without endpoints,
Ingresses to missing Services, node conditions), recent Warning events
(notable reasons at once, others after five repeats) and Deckhouse
ClusterAlerts mapped by their labels. A Problems panel lists them all.
Checked against the live cluster: upmeter's synthetic probe pods and
ingress-nginx's fakeservice Ingresses are excluded, they fail on purpose.

Actions: restart, scale, run a CronJob now, suspend/resume, delete a
pod, cordon/uncordon. They run with the viewer's bearer token from the
DexAuthenticator (sendAuthorizationHeader), buttons follow a
SelfSubjectAccessReview, the service account stays read-only. Cross-site
writes are refused by Sec-Fetch-Site/Origin/content type. Scale retries
on conflict: right after a restart a single Get+Update got 409.

Load (metrics.k8s.io against requests/limits/allocatable, per-pod table)
and an Events tab. Cards are locked until the padlock is opened; the map
exports to PNG; the page refreshes badges every minute in place.

Performance, measured on the live cluster:
- layout of big views 3-4x faster: equal-size cards with no edges are
  laid out on the grid ELK would produce (same sizes, checked against
  ELK on a frozen node view), skipping ~8 ms per ELK call;
- hubble-relay gets ~20% fewer flows: the to-overlay copy of pod-to-pod
  traffic is dropped at the agents; 331/331 directions unchanged;
- static files carry ETags, a reload revalidates instead of pulling
  ~2 MB of vendored scripts.

KUBECONFIG is honoured for running the binary on a workstation.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-24 17:25:36 +03:00

204 lines
8.3 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
type: object
properties:
traffic:
type: object
default: {}
description: Live traffic between workloads, read from Cilium Hubble Relay.
properties:
mode:
type: string
default: Continuous
enum: ["Continuous", "OnDemand", "Disabled"]
description: |
When flows are read from Hubble.
- `Continuous` — a Hubble follow stream is always open, so every traffic window is full as soon as the map is opened. Costs hubble-relay about 100–150m CPU on a busy cluster.
- `OnDemand` — the stream opens with the first traffic request and closes after `onDemandIdleMinutes` without one. Near-zero cost while nobody looks at the map, but windows only fill while it is in use.
- `Disabled` — no connection to Hubble; the map shows configuration links only.
Traffic also stays off when the `cilium-hubble` module is disabled.
retentionMinutes:
type: integer
default: 60
minimum: 5
maximum: 1440
description: |
How far back traffic windows can reach, in minutes. Memory grows with retention and with the number of distinct connections in the cluster.
onDemandIdleMinutes:
type: integer
default: 10
minimum: 1
maximum: 120
description: In `OnDemand` mode, how long the stream stays open after the last traffic request.
collectInfraTraffic:
type: boolean
default: false
description: |
Also collect kubelet probes and other traffic originating from node hosts, node-to-node traffic, Cilium health checks and DNS.
Off by default: on a typical cluster this is about three quarters of all flows, none of it maps to a workload, and filtering it at the Hubble agents keeps hubble-relay load several times lower.
actions:
type: object
default: {}
description: Changes the map can make to the cluster.
properties:
enabled:
type: boolean
default: true
description: |
Buttons to restart a workload, scale a Deployment or StatefulSet, delete a pod, run a CronJob now or suspend it, cordon a node.
Every action runs with the viewer's own Kubernetes identity: the DexAuthenticator passes the user's token to the module, and the API server checks it against the user's RBAC. The module's service account stays read-only, a button is shown only when the user's role allows it, and the API server's audit log records the user.
Needs the `user-authn` module, or an `externalAuthentication` that puts a token the API server accepts into the `Authorization` header. When disabled, the user's token is not passed to the module at all.
logs:
type: object
default: {}
properties:
tailLines:
type: integer
default: 500
minimum: 10
maximum: 10000
description: How many last lines of a container log the Logs tab shows.
systemNamespacePrefixes:
type: array
default: ["d8-", "kube-"]
items:
type: string
description: |
Namespaces grouped as "System" in the inventory tree. An entry ending in `-` matches by prefix, any other entry matches the whole name.
ingressClass:
type: string
pattern: '^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$'
description: |
The class of the Ingress controller used for the web interface.
Optional. By default, the `modules.ingressClass` global value is used.
nodeSelector:
type: object
additionalProperties:
type: string
description: |
The same as the `spec.nodeSelector` pod parameter in Kubernetes.
If the parameter is omitted or `false`, it will be determined [automatically](https://deckhouse.io/products/kubernetes-platform/documentation/v1/#advanced-scheduling).
tolerations:
type: array
description: |
The same as `spec.tolerations` for the Kubernetes Pod.
If the parameter is omitted or `false`, it will be determined [automatically](https://deckhouse.io/products/kubernetes-platform/documentation/v1/#advanced-scheduling).
items:
type: object
properties:
effect:
type: string
key:
type: string
operator:
type: string
tolerationSeconds:
type: integer
format: int64
value:
type: string
auth:
type: object
default: {}
description: |
Access to the web interface.
Anyone admitted here sees every namespace, the manifests of workloads, Services and Ingresses (never Secrets) and container logs, through the module's own read-only service account. Restrict access with `allowedUserGroups`.
properties:
externalAuthentication:
type: object
description: |
Parameters to enable external authentication based on the Ingress NGINX [external-auth](https://kubernetes.github.io/ingress-nginx/examples/auth/external-auth/) mechanism.
> External authentication is enabled automatically if the [user-authn](https://deckhouse.io/modules/user-authn/) module is enabled.
properties:
authURL:
type: string
x-examples: ["https://example.com/dex/auth"]
description: The URL of the authentication service. If the user is authenticated, the service should return an HTTP 200 response code.
authSignInURL:
type: string
x-examples: ["https://example.com/dex/sign_in"]
description: The URL to redirect the user for authentication (if the authentication service returned a non-200 HTTP response code).
allowedUserEmails:
type: array
items:
type: string
description: |
Emails of users allowed to open the web interface.
Used if the `user-authn` module is enabled or `externalAuthentication` is set.
allowedUserGroups:
type: array
items:
type: string
x-examples:
- ["admins"]
description: |
User groups allowed to open the web interface.
Used if the `user-authn` module is enabled or `externalAuthentication` is set.
**Caution!** When used together with the [user-authn](https://deckhouse.io/modules/user-authn/) module, add these groups to the matching field of the DexProvider.
whitelistSourceRanges:
type: array
items:
type: string
x-examples:
- ["1.1.1.1/32"]
description: CIDRs allowed to open the web interface.
https:
type: object
x-examples:
- mode: Disabled
- mode: OnlyInURI
- mode: CustomCertificate
customCertificate:
secretName: "foobar"
- mode: CertManager
certManager:
clusterIssuerName: letsencrypt
description: |
What certificate type to use.
This parameter completely overrides the `global.modules.https` settings.
properties:
mode:
type: string
default: "CertManager"
description: |
The HTTPS usage mode:
- `CertManager` — the web interface is served over HTTPS with a certificate from the ClusterIssuer set in `certManager.clusterIssuerName`;
- `CustomCertificate` — the web interface is served over HTTPS with a certificate from the `d8-system` namespace;
- `Disabled` — the web interface is served over HTTP only;
- `OnlyInURI` — the web interface is served over HTTP behind an external HTTPS load balancer that terminates TLS; links are generated with the HTTPS scheme.
enum:
- "Disabled"
- "CertManager"
- "CustomCertificate"
- "OnlyInURI"
certManager:
type: object
properties:
clusterIssuerName:
type: string
default: "letsencrypt"
x-examples: ["letsencrypt", "letsencrypt-staging", "selfsigned"]
description: The ClusterIssuer used to get the certificate.
customCertificate:
type: object
default: {}
properties:
secretName:
type: string
description: |
The name of the Secret in the `d8-system` namespace to use for the web interface.
The Secret must have the [kubernetes.io/tls](https://kubernetes.github.io/ingress-nginx/user-guide/tls/#tls-secrets) format.