@intentius/chant-lexicon-k8s 0.106.3 → 0.107.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/codegen/naming.d.ts.map +1 -1
- package/dist/codegen/versions.d.ts +5 -2
- package/dist/codegen/versions.d.ts.map +1 -1
- package/dist/composites/adot-collector.d.ts +6 -5
- package/dist/composites/adot-collector.d.ts.map +1 -1
- package/dist/composites/agic-ingress.d.ts +2 -1
- package/dist/composites/agic-ingress.d.ts.map +1 -1
- package/dist/composites/aks-external-dns-agent.d.ts +5 -4
- package/dist/composites/aks-external-dns-agent.d.ts.map +1 -1
- package/dist/composites/alb-ingress.d.ts +2 -1
- package/dist/composites/alb-ingress.d.ts.map +1 -1
- package/dist/composites/argo-app.d.ts +4 -3
- package/dist/composites/argo-app.d.ts.map +1 -1
- package/dist/composites/autoscaled-service.d.ts +5 -4
- package/dist/composites/autoscaled-service.d.ts.map +1 -1
- package/dist/composites/azure-disk-storage-class.d.ts +2 -1
- package/dist/composites/azure-disk-storage-class.d.ts.map +1 -1
- package/dist/composites/azure-file-storage-class.d.ts +2 -1
- package/dist/composites/azure-file-storage-class.d.ts.map +1 -1
- package/dist/composites/azure-monitor-collector.d.ts +6 -5
- package/dist/composites/azure-monitor-collector.d.ts.map +1 -1
- package/dist/composites/batch-job.d.ts +5 -4
- package/dist/composites/batch-job.d.ts.map +1 -1
- package/dist/composites/catalog.d.ts.map +1 -1
- package/dist/composites/cockroachdb-cluster.d.ts +12 -11
- package/dist/composites/cockroachdb-cluster.d.ts.map +1 -1
- package/dist/composites/configured-app.d.ts +4 -3
- package/dist/composites/configured-app.d.ts.map +1 -1
- package/dist/composites/cron-workload.d.ts +5 -4
- package/dist/composites/cron-workload.d.ts.map +1 -1
- package/dist/composites/ebs-storage-class.d.ts +2 -1
- package/dist/composites/ebs-storage-class.d.ts.map +1 -1
- package/dist/composites/efs-storage-class.d.ts +2 -1
- package/dist/composites/efs-storage-class.d.ts.map +1 -1
- package/dist/composites/external-dns-agent.d.ts +5 -4
- package/dist/composites/external-dns-agent.d.ts.map +1 -1
- package/dist/composites/filestore-storage-class.d.ts +2 -1
- package/dist/composites/filestore-storage-class.d.ts.map +1 -1
- package/dist/composites/fluent-bit-agent.d.ts +6 -5
- package/dist/composites/fluent-bit-agent.d.ts.map +1 -1
- package/dist/composites/flux-app.d.ts +3 -2
- package/dist/composites/flux-app.d.ts.map +1 -1
- package/dist/composites/gce-ingress.d.ts +2 -1
- package/dist/composites/gce-ingress.d.ts.map +1 -1
- package/dist/composites/gce-pd-storage-class.d.ts +2 -1
- package/dist/composites/gce-pd-storage-class.d.ts.map +1 -1
- package/dist/composites/gke-external-dns-agent.d.ts +5 -4
- package/dist/composites/gke-external-dns-agent.d.ts.map +1 -1
- package/dist/composites/gke-fluent-bit-agent.d.ts +6 -5
- package/dist/composites/gke-fluent-bit-agent.d.ts.map +1 -1
- package/dist/composites/gke-otel-collector.d.ts +6 -5
- package/dist/composites/gke-otel-collector.d.ts.map +1 -1
- package/dist/composites/index.d.ts +2 -0
- package/dist/composites/index.d.ts.map +1 -1
- package/dist/composites/inference-service.d.ts +2 -1
- package/dist/composites/inference-service.d.ts.map +1 -1
- package/dist/composites/irsa-service-account.d.ts +4 -3
- package/dist/composites/irsa-service-account.d.ts.map +1 -1
- package/dist/composites/member-defaults.d.ts +21 -0
- package/dist/composites/member-defaults.d.ts.map +1 -0
- package/dist/composites/metrics-server.d.ts +9 -8
- package/dist/composites/metrics-server.d.ts.map +1 -1
- package/dist/composites/model.d.ts +2 -1
- package/dist/composites/model.d.ts.map +1 -1
- package/dist/composites/monitored-service.d.ts +5 -4
- package/dist/composites/monitored-service.d.ts.map +1 -1
- package/dist/composites/namespace-env.d.ts +5 -4
- package/dist/composites/namespace-env.d.ts.map +1 -1
- package/dist/composites/network-isolated-app.d.ts +4 -3
- package/dist/composites/network-isolated-app.d.ts.map +1 -1
- package/dist/composites/node-agent.d.ts +6 -5
- package/dist/composites/node-agent.d.ts.map +1 -1
- package/dist/composites/operator-stack.d.ts +6 -5
- package/dist/composites/operator-stack.d.ts.map +1 -1
- package/dist/composites/otel-collector-agent.d.ts +6 -5
- package/dist/composites/otel-collector-agent.d.ts.map +1 -1
- package/dist/composites/otel-collector-gateway.d.ts +11 -10
- package/dist/composites/otel-collector-gateway.d.ts.map +1 -1
- package/dist/composites/otel-collector-rbac.d.ts +3 -2
- package/dist/composites/otel-collector-rbac.d.ts.map +1 -1
- package/dist/composites/otel-collector-shape.d.ts +2 -0
- package/dist/composites/otel-collector-shape.d.ts.map +1 -1
- package/dist/composites/otel-collector.d.ts +9 -8
- package/dist/composites/otel-collector.d.ts.map +1 -1
- package/dist/composites/otel-operator-collector.d.ts +101 -0
- package/dist/composites/otel-operator-collector.d.ts.map +1 -0
- package/dist/composites/ray-cluster.d.ts +10 -9
- package/dist/composites/ray-cluster.d.ts.map +1 -1
- package/dist/composites/ray-job.d.ts +7 -6
- package/dist/composites/ray-job.d.ts.map +1 -1
- package/dist/composites/ray-service.d.ts +9 -8
- package/dist/composites/ray-service.d.ts.map +1 -1
- package/dist/composites/secure-ingress.d.ts +3 -2
- package/dist/composites/secure-ingress.d.ts.map +1 -1
- package/dist/composites/sidecar-app.d.ts +3 -2
- package/dist/composites/sidecar-app.d.ts.map +1 -1
- package/dist/composites/stateful-app.d.ts +4 -3
- package/dist/composites/stateful-app.d.ts.map +1 -1
- package/dist/composites/vllm-serving-runtime.d.ts +2 -1
- package/dist/composites/vllm-serving-runtime.d.ts.map +1 -1
- package/dist/composites/web-app.d.ts +5 -4
- package/dist/composites/web-app.d.ts.map +1 -1
- package/dist/composites/worker-pool.d.ts +8 -7
- package/dist/composites/worker-pool.d.ts.map +1 -1
- package/dist/composites/workload-identity-sa.d.ts +4 -3
- package/dist/composites/workload-identity-sa.d.ts.map +1 -1
- package/dist/composites/workload-identity-service-account.d.ts +4 -3
- package/dist/composites/workload-identity-service-account.d.ts.map +1 -1
- package/dist/crd/crd-sources.d.ts.map +1 -1
- package/dist/generated/index.d.d.ts +8822 -0
- package/dist/generated/index.d.ts +301 -0
- package/dist/generated/index.d.ts.map +1 -1
- package/dist/group-namespace.d.ts.map +1 -1
- package/dist/import/embedded.d.ts +3 -0
- package/dist/import/embedded.d.ts.map +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/integrity.json +16 -9
- package/dist/lint/audit-catalog.d.ts.map +1 -1
- package/dist/lint/post-synth/index.d.ts.map +1 -1
- package/dist/lint/post-synth/monitoring-selection-helpers.d.ts +55 -0
- package/dist/lint/post-synth/monitoring-selection-helpers.d.ts.map +1 -0
- package/dist/lint/post-synth/otel-placement-helpers.d.ts +16 -0
- package/dist/lint/post-synth/otel-placement-helpers.d.ts.map +1 -1
- package/dist/lint/post-synth/wk8604.d.ts +6 -0
- package/dist/lint/post-synth/wk8604.d.ts.map +1 -1
- package/dist/lint/post-synth/wk8605.d.ts.map +1 -1
- package/dist/lint/post-synth/wk8606.d.ts +17 -0
- package/dist/lint/post-synth/wk8606.d.ts.map +1 -0
- package/dist/lint/post-synth/wk8701.d.ts +17 -0
- package/dist/lint/post-synth/wk8701.d.ts.map +1 -0
- package/dist/lint/post-synth/wk8702.d.ts +17 -0
- package/dist/lint/post-synth/wk8702.d.ts.map +1 -0
- package/dist/lint/post-synth/wk8703.d.ts +17 -0
- package/dist/lint/post-synth/wk8703.d.ts.map +1 -0
- package/dist/lint/post-synth/wk8704.d.ts +21 -0
- package/dist/lint/post-synth/wk8704.d.ts.map +1 -0
- package/dist/lint/post-synth/wk8705.d.ts +18 -0
- package/dist/lint/post-synth/wk8705.d.ts.map +1 -0
- package/dist/manifest.json +1 -1
- package/dist/meta.json +2284 -370
- package/dist/okf/index.md +20 -1
- package/dist/okf/rules/WK8604.md +6 -2
- package/dist/okf/rules/WK8605.md +4 -0
- package/dist/okf/rules/WK8606.md +15 -0
- package/dist/okf/rules/WK8701.md +18 -0
- package/dist/okf/rules/WK8702.md +20 -0
- package/dist/okf/rules/WK8703.md +17 -0
- package/dist/okf/rules/WK8704.md +22 -0
- package/dist/okf/rules/WK8705.md +18 -0
- package/dist/okf/types/Alertmanager.md +18 -0
- package/dist/okf/types/AlertmanagerConfig.md +18 -0
- package/dist/okf/types/ClusterObservability.md +14 -0
- package/dist/okf/types/CronJob.md +1 -0
- package/dist/okf/types/DaemonSet.md +1 -0
- package/dist/okf/types/Instrumentation.md +14 -0
- package/dist/okf/types/MonitoringProbe.md +14 -0
- package/dist/okf/types/Namespace.md +3 -0
- package/dist/okf/types/OpAMPBridge.md +14 -0
- package/dist/okf/types/OpenTelemetryCollector.md +19 -0
- package/dist/okf/types/Pod.md +1 -0
- package/dist/okf/types/PodMonitor.md +20 -0
- package/dist/okf/types/Prometheus.md +21 -0
- package/dist/okf/types/PrometheusAgent.md +18 -0
- package/dist/okf/types/PrometheusRule.md +6 -1
- package/dist/okf/types/ScrapeConfig.md +19 -0
- package/dist/okf/types/Service.md +1 -0
- package/dist/okf/types/ServiceMonitor.md +7 -1
- package/dist/okf/types/StatefulSet.md +1 -0
- package/dist/okf/types/TargetAllocator.md +14 -0
- package/dist/okf/types/ThanosRuler.md +18 -0
- package/dist/rules/monitoring-selection-helpers.ts +185 -0
- package/dist/rules/otel-placement-helpers.ts +61 -1
- package/dist/rules/wk8601.ts +1 -1
- package/dist/rules/wk8603.ts +1 -1
- package/dist/rules/wk8604.ts +8 -2
- package/dist/rules/wk8605.ts +5 -3
- package/dist/rules/wk8606.ts +27 -0
- package/dist/rules/wk8701.ts +37 -0
- package/dist/rules/wk8702.ts +43 -0
- package/dist/rules/wk8703.ts +37 -0
- package/dist/rules/wk8704.ts +134 -0
- package/dist/rules/wk8705.ts +45 -0
- package/dist/types/index.d.ts +172 -2
- package/package.json +4 -4
- package/src/codegen/naming.ts +15 -1
- package/src/codegen/versions.ts +6 -2
- package/src/composites/adot-collector.ts +6 -5
- package/src/composites/agic-ingress.ts +2 -1
- package/src/composites/aks-external-dns-agent.ts +5 -4
- package/src/composites/alb-ingress.ts +2 -1
- package/src/composites/argo-app.ts +4 -3
- package/src/composites/autoscaled-service.ts +5 -4
- package/src/composites/azure-disk-storage-class.ts +2 -1
- package/src/composites/azure-file-storage-class.ts +2 -1
- package/src/composites/azure-monitor-collector.ts +6 -5
- package/src/composites/batch-job.ts +5 -4
- package/src/composites/catalog.ts +105 -0
- package/src/composites/cockroachdb-cluster.ts +12 -11
- package/src/composites/configured-app.ts +4 -3
- package/src/composites/cron-workload.ts +5 -4
- package/src/composites/ebs-storage-class.ts +2 -1
- package/src/composites/efs-storage-class.ts +2 -1
- package/src/composites/external-dns-agent.ts +5 -4
- package/src/composites/filestore-storage-class.ts +2 -1
- package/src/composites/fluent-bit-agent.ts +6 -5
- package/src/composites/flux-app.ts +3 -2
- package/src/composites/gce-ingress.ts +2 -1
- package/src/composites/gce-pd-storage-class.ts +2 -1
- package/src/composites/gke-external-dns-agent.ts +5 -4
- package/src/composites/gke-fluent-bit-agent.ts +6 -5
- package/src/composites/gke-otel-collector.ts +6 -5
- package/src/composites/index.ts +2 -0
- package/src/composites/inference-service.ts +2 -1
- package/src/composites/irsa-service-account.ts +4 -3
- package/src/composites/member-defaults.test.ts +63 -0
- package/src/composites/member-defaults.ts +29 -0
- package/src/composites/metrics-server.ts +9 -8
- package/src/composites/model.ts +3 -2
- package/src/composites/monitored-service.ts +5 -4
- package/src/composites/namespace-env.ts +5 -4
- package/src/composites/network-isolated-app.ts +4 -3
- package/src/composites/node-agent.ts +6 -5
- package/src/composites/operator-stack.ts +6 -5
- package/src/composites/otel-collector-agent.ts +6 -5
- package/src/composites/otel-collector-gateway.ts +11 -10
- package/src/composites/otel-collector-rbac.ts +3 -2
- package/src/composites/otel-collector-shape.ts +2 -0
- package/src/composites/otel-collector.ts +9 -8
- package/src/composites/otel-operator-collector.test.ts +267 -0
- package/src/composites/otel-operator-collector.ts +221 -0
- package/src/composites/ray-cluster.ts +10 -9
- package/src/composites/ray-job.ts +7 -6
- package/src/composites/ray-service.ts +9 -8
- package/src/composites/secure-ingress.ts +3 -2
- package/src/composites/sidecar-app.ts +3 -2
- package/src/composites/stateful-app.ts +4 -3
- package/src/composites/vllm-serving-runtime.ts +2 -1
- package/src/composites/web-app.ts +5 -4
- package/src/composites/worker-pool.ts +8 -7
- package/src/composites/workload-identity-sa.ts +4 -3
- package/src/composites/workload-identity-service-account.ts +4 -3
- package/src/crd/crd-sources.ts +41 -2
- package/src/generated/index.d.ts +172 -2
- package/src/generated/index.ts +303 -2
- package/src/generated/lexicon-k8s.json +2284 -370
- package/src/generated/operations.json +208 -0
- package/src/group-namespace.test.ts +4 -0
- package/src/group-namespace.ts +4 -0
- package/src/import/embedded.ts +26 -0
- package/src/import/operator-collector-roundtrip.test.ts +105 -0
- package/src/index.ts +2 -2
- package/src/lint/audit-catalog.ts +6 -0
- package/src/lint/post-synth/index.ts +12 -0
- package/src/lint/post-synth/monitoring-selection-helpers.ts +185 -0
- package/src/lint/post-synth/monitoring-selection.test.ts +316 -0
- package/src/lint/post-synth/otel-placement-helpers.ts +61 -1
- package/src/lint/post-synth/wk8601.ts +1 -1
- package/src/lint/post-synth/wk8603.ts +1 -1
- package/src/lint/post-synth/wk8604.ts +8 -2
- package/src/lint/post-synth/wk8605.ts +5 -3
- package/src/lint/post-synth/wk8606.ts +27 -0
- package/src/lint/post-synth/wk8701.ts +37 -0
- package/src/lint/post-synth/wk8702.ts +43 -0
- package/src/lint/post-synth/wk8703.ts +37 -0
- package/src/lint/post-synth/wk8704.ts +134 -0
- package/src/lint/post-synth/wk8705.ts +45 -0
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* WK8705: a Prometheus whose four monitor selectors are all null
|
|
3
|
+
*
|
|
4
|
+
* A Prometheus picks the ServiceMonitors, PodMonitors, Probes and
|
|
5
|
+
* ScrapeConfigs to scrape with `serviceMonitorSelector`, `podMonitorSelector`,
|
|
6
|
+
* `probeSelector` and `scrapeConfigSelector`. A null selector (absent counts
|
|
7
|
+
* as null) matches nothing, so a Prometheus with all four null selects no
|
|
8
|
+
* monitor at all and scrapes only what `additionalScrapeConfigs` and its own
|
|
9
|
+
* config hold. `{}` matches every monitor in the selected namespaces. This is
|
|
10
|
+
* the usual way a fresh Prometheus ends up scraping nothing.
|
|
11
|
+
*
|
|
12
|
+
* A Prometheus with `additionalScrapeConfigs` set still reports: that
|
|
13
|
+
* is a deliberate setup the finding names, not one it hides. The message says
|
|
14
|
+
* so, and a suppression is the way to accept it.
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
import type { PostSynthCheck, PostSynthContext, PostSynthDiagnostic } from "@intentius/chant/lint/post-synth";
|
|
18
|
+
import { describe, monitoringKind, nameOf, selectionContext } from "./monitoring-selection-helpers";
|
|
19
|
+
|
|
20
|
+
const SELECTORS = ["serviceMonitorSelector", "podMonitorSelector", "probeSelector", "scrapeConfigSelector"] as const;
|
|
21
|
+
|
|
22
|
+
export const wk8705: PostSynthCheck = {
|
|
23
|
+
id: "WK8705",
|
|
24
|
+
description:
|
|
25
|
+
"A Prometheus whose serviceMonitorSelector, podMonitorSelector, probeSelector and scrapeConfigSelector are all null selects no monitor, so the operator scrapes nothing from ServiceMonitors, PodMonitors, Probes or ScrapeConfigs.",
|
|
26
|
+
|
|
27
|
+
check(ctx: PostSynthContext): PostSynthDiagnostic[] {
|
|
28
|
+
const { manifests } = selectionContext(ctx);
|
|
29
|
+
return monitoringKind(manifests, "Prometheus")
|
|
30
|
+
.filter((p) => {
|
|
31
|
+
const spec = (p.spec ?? {}) as Record<string, unknown>;
|
|
32
|
+
return SELECTORS.every((k) => spec[k] === null || spec[k] === undefined);
|
|
33
|
+
})
|
|
34
|
+
.map((p) => ({
|
|
35
|
+
checkId: "WK8705",
|
|
36
|
+
severity: "warning" as const,
|
|
37
|
+
message:
|
|
38
|
+
`${describe(p)} has ${SELECTORS.join(", ")} all null, so it selects no ServiceMonitor, PodMonitor, Probe or ScrapeConfig and scrapes only its own config` +
|
|
39
|
+
`${(p.spec as Record<string, unknown> | undefined)?.additionalScrapeConfigs ? " and additionalScrapeConfigs" : ""}. ` +
|
|
40
|
+
`Set the selector for each monitor kind it should pick up ({} selects all in the selected namespaces).`,
|
|
41
|
+
entity: nameOf(p),
|
|
42
|
+
lexicon: "k8s",
|
|
43
|
+
}));
|
|
44
|
+
},
|
|
45
|
+
};
|
package/dist/types/index.d.ts
CHANGED
|
@@ -26,6 +26,33 @@ export declare class Alert {
|
|
|
26
26
|
readonly uid: string;
|
|
27
27
|
}
|
|
28
28
|
|
|
29
|
+
export declare class Alertmanager {
|
|
30
|
+
constructor(props: {
|
|
31
|
+
/** spec defines the specification of the desired behavior of the Alertmanager cluster. More info:
|
|
32
|
+
https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md#spec-and-status */
|
|
33
|
+
spec: Record<string, unknown>;
|
|
34
|
+
/** Standard object's metadata. */
|
|
35
|
+
metadata?: ObjectMeta;
|
|
36
|
+
});
|
|
37
|
+
readonly name: string;
|
|
38
|
+
readonly namespace: string;
|
|
39
|
+
readonly status: Record<string, unknown>;
|
|
40
|
+
readonly uid: string;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export declare class AlertmanagerConfig {
|
|
44
|
+
constructor(props: {
|
|
45
|
+
/** spec defines the specification of AlertmanagerConfigSpec */
|
|
46
|
+
spec: Record<string, unknown>;
|
|
47
|
+
/** Standard object's metadata. */
|
|
48
|
+
metadata?: ObjectMeta;
|
|
49
|
+
});
|
|
50
|
+
readonly name: string;
|
|
51
|
+
readonly namespace: string;
|
|
52
|
+
readonly status: Record<string, unknown>;
|
|
53
|
+
readonly uid: string;
|
|
54
|
+
}
|
|
55
|
+
|
|
29
56
|
export declare class APIGroup {
|
|
30
57
|
constructor(props: {
|
|
31
58
|
/** name is the name of the group. */
|
|
@@ -317,6 +344,18 @@ export declare class ClusterIssuer {
|
|
|
317
344
|
readonly uid: string;
|
|
318
345
|
}
|
|
319
346
|
|
|
347
|
+
export declare class ClusterObservability {
|
|
348
|
+
constructor(props: {
|
|
349
|
+
/** Standard object's metadata. */
|
|
350
|
+
metadata?: ObjectMeta;
|
|
351
|
+
spec?: Record<string, unknown>;
|
|
352
|
+
});
|
|
353
|
+
readonly name: string;
|
|
354
|
+
readonly namespace: string;
|
|
355
|
+
readonly status: Record<string, unknown>;
|
|
356
|
+
readonly uid: string;
|
|
357
|
+
}
|
|
358
|
+
|
|
320
359
|
export declare class ClusterResourceSet {
|
|
321
360
|
constructor(props: {
|
|
322
361
|
/** spec is the desired state of ClusterResourceSet. */
|
|
@@ -1569,6 +1608,18 @@ export declare class IngressRouteUDP {
|
|
|
1569
1608
|
readonly uid: string;
|
|
1570
1609
|
}
|
|
1571
1610
|
|
|
1611
|
+
export declare class Instrumentation {
|
|
1612
|
+
constructor(props: {
|
|
1613
|
+
/** Standard object's metadata. */
|
|
1614
|
+
metadata?: ObjectMeta;
|
|
1615
|
+
spec?: Record<string, unknown>;
|
|
1616
|
+
});
|
|
1617
|
+
readonly name: string;
|
|
1618
|
+
readonly namespace: string;
|
|
1619
|
+
readonly status: Record<string, unknown>;
|
|
1620
|
+
readonly uid: string;
|
|
1621
|
+
}
|
|
1622
|
+
|
|
1572
1623
|
export declare class IPAddress {
|
|
1573
1624
|
constructor(props: {
|
|
1574
1625
|
/** spec is the desired state of the IPAddress. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status */
|
|
@@ -1837,6 +1888,19 @@ export declare class MiddlewareTCP {
|
|
|
1837
1888
|
readonly uid: string;
|
|
1838
1889
|
}
|
|
1839
1890
|
|
|
1891
|
+
export declare class MonitoringProbe {
|
|
1892
|
+
constructor(props: {
|
|
1893
|
+
/** spec defines the specification of desired Ingress selection for target discovery by Prometheus. */
|
|
1894
|
+
spec: Record<string, unknown>;
|
|
1895
|
+
/** Standard object's metadata. */
|
|
1896
|
+
metadata?: ObjectMeta;
|
|
1897
|
+
});
|
|
1898
|
+
readonly name: string;
|
|
1899
|
+
readonly namespace: string;
|
|
1900
|
+
readonly status: Record<string, unknown>;
|
|
1901
|
+
readonly uid: string;
|
|
1902
|
+
}
|
|
1903
|
+
|
|
1840
1904
|
export declare class MutatingAdmissionPolicy {
|
|
1841
1905
|
constructor(props: {
|
|
1842
1906
|
/** metadata is the standard object metadata; More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata. */
|
|
@@ -2032,6 +2096,30 @@ export declare class OCIRepository {
|
|
|
2032
2096
|
readonly uid: string;
|
|
2033
2097
|
}
|
|
2034
2098
|
|
|
2099
|
+
export declare class OpAMPBridge {
|
|
2100
|
+
constructor(props: {
|
|
2101
|
+
/** Standard object's metadata. */
|
|
2102
|
+
metadata?: ObjectMeta;
|
|
2103
|
+
spec?: Record<string, unknown>;
|
|
2104
|
+
});
|
|
2105
|
+
readonly name: string;
|
|
2106
|
+
readonly namespace: string;
|
|
2107
|
+
readonly status: Record<string, unknown>;
|
|
2108
|
+
readonly uid: string;
|
|
2109
|
+
}
|
|
2110
|
+
|
|
2111
|
+
export declare class OpenTelemetryCollector {
|
|
2112
|
+
constructor(props: {
|
|
2113
|
+
/** Standard object's metadata. */
|
|
2114
|
+
metadata?: ObjectMeta;
|
|
2115
|
+
spec?: Record<string, unknown>;
|
|
2116
|
+
});
|
|
2117
|
+
readonly name: string;
|
|
2118
|
+
readonly namespace: string;
|
|
2119
|
+
readonly status: Record<string, unknown>;
|
|
2120
|
+
readonly uid: string;
|
|
2121
|
+
}
|
|
2122
|
+
|
|
2035
2123
|
export declare class Order {
|
|
2036
2124
|
constructor(props: {
|
|
2037
2125
|
spec: Record<string, unknown>;
|
|
@@ -2193,6 +2281,19 @@ export declare class PodList {
|
|
|
2193
2281
|
readonly uid: string;
|
|
2194
2282
|
}
|
|
2195
2283
|
|
|
2284
|
+
export declare class PodMonitor {
|
|
2285
|
+
constructor(props: {
|
|
2286
|
+
/** spec defines the specification of desired Pod selection for target discovery by Prometheus. */
|
|
2287
|
+
spec: Record<string, unknown>;
|
|
2288
|
+
/** Standard object's metadata. */
|
|
2289
|
+
metadata?: ObjectMeta;
|
|
2290
|
+
});
|
|
2291
|
+
readonly name: string;
|
|
2292
|
+
readonly namespace: string;
|
|
2293
|
+
readonly status: Record<string, unknown>;
|
|
2294
|
+
readonly uid: string;
|
|
2295
|
+
}
|
|
2296
|
+
|
|
2196
2297
|
export declare class PodTemplate {
|
|
2197
2298
|
constructor(props: {
|
|
2198
2299
|
/** Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata */
|
|
@@ -2307,15 +2408,44 @@ export declare class PriorityLevelConfigurationList {
|
|
|
2307
2408
|
readonly uid: string;
|
|
2308
2409
|
}
|
|
2309
2410
|
|
|
2411
|
+
export declare class Prometheus {
|
|
2412
|
+
constructor(props: {
|
|
2413
|
+
/** spec defines the specification of the desired behavior of the Prometheus cluster. More info:
|
|
2414
|
+
https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md#spec-and-status */
|
|
2415
|
+
spec: Record<string, unknown>;
|
|
2416
|
+
/** Standard object's metadata. */
|
|
2417
|
+
metadata?: ObjectMeta;
|
|
2418
|
+
});
|
|
2419
|
+
readonly name: string;
|
|
2420
|
+
readonly namespace: string;
|
|
2421
|
+
readonly status: Record<string, unknown>;
|
|
2422
|
+
readonly uid: string;
|
|
2423
|
+
}
|
|
2424
|
+
|
|
2425
|
+
export declare class PrometheusAgent {
|
|
2426
|
+
constructor(props: {
|
|
2427
|
+
/** spec defines the specification of the desired behavior of the Prometheus agent. More info:
|
|
2428
|
+
https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md#spec-and-status */
|
|
2429
|
+
spec: Record<string, unknown>;
|
|
2430
|
+
/** Standard object's metadata. */
|
|
2431
|
+
metadata?: ObjectMeta;
|
|
2432
|
+
});
|
|
2433
|
+
readonly name: string;
|
|
2434
|
+
readonly namespace: string;
|
|
2435
|
+
readonly status: Record<string, unknown>;
|
|
2436
|
+
readonly uid: string;
|
|
2437
|
+
}
|
|
2438
|
+
|
|
2310
2439
|
export declare class PrometheusRule {
|
|
2311
2440
|
constructor(props: {
|
|
2312
|
-
/**
|
|
2441
|
+
/** spec defines the specification of desired alerting rule definitions for Prometheus. */
|
|
2313
2442
|
spec: Record<string, unknown>;
|
|
2314
2443
|
/** Standard object's metadata. */
|
|
2315
2444
|
metadata?: ObjectMeta;
|
|
2316
2445
|
});
|
|
2317
2446
|
readonly name: string;
|
|
2318
2447
|
readonly namespace: string;
|
|
2448
|
+
readonly status: Record<string, unknown>;
|
|
2319
2449
|
readonly uid: string;
|
|
2320
2450
|
}
|
|
2321
2451
|
|
|
@@ -2726,6 +2856,19 @@ More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-
|
|
|
2726
2856
|
readonly uid: string;
|
|
2727
2857
|
}
|
|
2728
2858
|
|
|
2859
|
+
export declare class ScrapeConfig {
|
|
2860
|
+
constructor(props: {
|
|
2861
|
+
/** spec defines the specification of ScrapeConfigSpec. */
|
|
2862
|
+
spec: Record<string, unknown>;
|
|
2863
|
+
/** Standard object's metadata. */
|
|
2864
|
+
metadata?: ObjectMeta;
|
|
2865
|
+
});
|
|
2866
|
+
readonly name: string;
|
|
2867
|
+
readonly namespace: string;
|
|
2868
|
+
readonly status: Record<string, unknown>;
|
|
2869
|
+
readonly uid: string;
|
|
2870
|
+
}
|
|
2871
|
+
|
|
2729
2872
|
export declare class Sec {
|
|
2730
2873
|
constructor(props: {
|
|
2731
2874
|
/** Data contains the secret data. Each key must consist of alphanumeric characters, '-', '_' or '.'. The serialized form of the secret data is a base64 encoded string, representing the arbitrary (possibly non-string) data value here. Described in https://tools.ietf.org/html/rfc4648#section-4 */
|
|
@@ -2910,7 +3053,7 @@ export declare class ServiceList {
|
|
|
2910
3053
|
|
|
2911
3054
|
export declare class ServiceMonitor {
|
|
2912
3055
|
constructor(props: {
|
|
2913
|
-
/**
|
|
3056
|
+
/** spec defines the specification of desired Service selection for target discovery by
|
|
2914
3057
|
Prometheus. */
|
|
2915
3058
|
spec: Record<string, unknown>;
|
|
2916
3059
|
/** Standard object's metadata. */
|
|
@@ -2918,6 +3061,7 @@ Prometheus. */
|
|
|
2918
3061
|
});
|
|
2919
3062
|
readonly name: string;
|
|
2920
3063
|
readonly namespace: string;
|
|
3064
|
+
readonly status: Record<string, unknown>;
|
|
2921
3065
|
readonly uid: string;
|
|
2922
3066
|
}
|
|
2923
3067
|
|
|
@@ -3059,6 +3203,32 @@ export declare class SubjectAccessReview {
|
|
|
3059
3203
|
readonly uid: string;
|
|
3060
3204
|
}
|
|
3061
3205
|
|
|
3206
|
+
export declare class TargetAllocator {
|
|
3207
|
+
constructor(props: {
|
|
3208
|
+
/** Standard object's metadata. */
|
|
3209
|
+
metadata?: ObjectMeta;
|
|
3210
|
+
spec?: Record<string, unknown>;
|
|
3211
|
+
});
|
|
3212
|
+
readonly name: string;
|
|
3213
|
+
readonly namespace: string;
|
|
3214
|
+
readonly status: Record<string, unknown>;
|
|
3215
|
+
readonly uid: string;
|
|
3216
|
+
}
|
|
3217
|
+
|
|
3218
|
+
export declare class ThanosRuler {
|
|
3219
|
+
constructor(props: {
|
|
3220
|
+
/** spec defines the specification of the desired behavior of the ThanosRuler cluster. More info:
|
|
3221
|
+
https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md#spec-and-status */
|
|
3222
|
+
spec: Record<string, unknown>;
|
|
3223
|
+
/** Standard object's metadata. */
|
|
3224
|
+
metadata?: ObjectMeta;
|
|
3225
|
+
});
|
|
3226
|
+
readonly name: string;
|
|
3227
|
+
readonly namespace: string;
|
|
3228
|
+
readonly status: Record<string, unknown>;
|
|
3229
|
+
readonly uid: string;
|
|
3230
|
+
}
|
|
3231
|
+
|
|
3062
3232
|
export declare class TLSOption {
|
|
3063
3233
|
constructor(props: {
|
|
3064
3234
|
/** TLSOptionSpec defines the desired state of a TLSOption. */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@intentius/chant-lexicon-k8s",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.107.1",
|
|
4
4
|
"description": "Kubernetes lexicon for chant — declarative IaC in TypeScript",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"homepage": "https://intentius.io/chant",
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
"validate": "tsx src/validate-cli.ts",
|
|
70
70
|
"docs": "tsx src/codegen/docs-cli.ts",
|
|
71
71
|
"prepack": "npm run generate && npm run bundle && npm run validate && npm run build",
|
|
72
|
-
"build": "../../scripts/tsc7.sh -p tsconfig.build.json && tsc-alias -p tsconfig.build.json && find dist -type f \\( -name \"*.js\" -o -name \"*.js.map\" \\) -delete"
|
|
72
|
+
"build": "../../scripts/tsc7.sh -p tsconfig.build.json && tsc-alias -p tsconfig.build.json && find dist -type f \\( -name \"*.js\" -o -name \"*.js.map\" \\) -delete && cp src/generated/index.d.ts dist/generated/index.d.d.ts"
|
|
73
73
|
},
|
|
74
74
|
"dependencies": {
|
|
75
75
|
"@intentius/chant-lexicon-otel": "*",
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"@types/js-yaml": "^4.0.9"
|
|
79
79
|
},
|
|
80
80
|
"optionalDependencies": {
|
|
81
|
-
"@intentius/chant-k8s-client": "^0.
|
|
81
|
+
"@intentius/chant-k8s-client": "^0.107.1"
|
|
82
82
|
},
|
|
83
83
|
"devDependencies": {
|
|
84
84
|
"@intentius/chant": "*",
|
|
@@ -86,7 +86,7 @@
|
|
|
86
86
|
},
|
|
87
87
|
"peerDependencies": {
|
|
88
88
|
"zod": "^4.3.6",
|
|
89
|
-
"@intentius/chant": "^0.
|
|
89
|
+
"@intentius/chant": "^0.107.1",
|
|
90
90
|
"typescript": "^5.9.3"
|
|
91
91
|
}
|
|
92
92
|
}
|
package/src/codegen/naming.ts
CHANGED
|
@@ -80,6 +80,9 @@ const k8sNamingConfig: NamingConfig = {
|
|
|
80
80
|
// Events (core vs events.k8s.io — the core version wins)
|
|
81
81
|
"K8s::Core::Event": "Event",
|
|
82
82
|
|
|
83
|
+
// Prometheus Operator's Probe CRD would collide with the core Probe property type
|
|
84
|
+
"K8s::Monitoring::Probe": "MonitoringProbe",
|
|
85
|
+
|
|
83
86
|
// Property types
|
|
84
87
|
"K8s::Core::Container": "Container",
|
|
85
88
|
"K8s::Core::ContainerPort": "ContainerPort",
|
|
@@ -150,7 +153,18 @@ const k8sNamingConfig: NamingConfig = {
|
|
|
150
153
|
"K8s::Networking::NetworkPolicy": ["NetPol"],
|
|
151
154
|
},
|
|
152
155
|
|
|
153
|
-
|
|
156
|
+
// Names published before the Prometheus Operator CRDs (v0.94.1) added colliding
|
|
157
|
+
// property types stay with their original owners; the new CRDs' types are prefixed.
|
|
158
|
+
priorityPropertyAliases: {
|
|
159
|
+
"K8s::Monitoring::ServiceMonitor": {
|
|
160
|
+
AttachMetadata: "AttachMetadata",
|
|
161
|
+
NamespaceSelector: "NamespaceSelector",
|
|
162
|
+
Selector: "Selector",
|
|
163
|
+
},
|
|
164
|
+
"K8s::Traefik::Middleware": { BasicAuth: "BasicAuth" },
|
|
165
|
+
"K8s::Addons::HelmChartProxy": { TlsConfig: "TlsConfig" },
|
|
166
|
+
"K8s::S3::Bucket": { Lifecycle: "Lifecycle" },
|
|
167
|
+
},
|
|
154
168
|
|
|
155
169
|
serviceAbbreviations: {
|
|
156
170
|
Core: "Core",
|
package/src/codegen/versions.ts
CHANGED
|
@@ -6,10 +6,14 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
import { fetchWithRetry } from "@intentius/chant/codegen/fetch";
|
|
9
|
+
import { K8S_SCHEMA_VERSION } from "../spec/fetch";
|
|
9
10
|
|
|
10
|
-
/**
|
|
11
|
+
/**
|
|
12
|
+
* Pinned versions of external dependencies. The Kubernetes entry mirrors
|
|
13
|
+
* K8S_SCHEMA_VERSION in spec/fetch.ts, which is the version codegen downloads.
|
|
14
|
+
*/
|
|
11
15
|
export const PINNED_VERSIONS = {
|
|
12
|
-
k8sOpenAPI:
|
|
16
|
+
k8sOpenAPI: K8S_SCHEMA_VERSION,
|
|
13
17
|
} as const;
|
|
14
18
|
|
|
15
19
|
/**
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { Composite, mergeDefaults } from "@intentius/chant";
|
|
9
9
|
import { DaemonSet, ServiceAccount, ClusterRole, ClusterRoleBinding, ConfigMap } from "../generated";
|
|
10
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
10
11
|
|
|
11
12
|
export interface AdotCollectorProps {
|
|
12
13
|
/** AWS region. */
|
|
@@ -35,11 +36,11 @@ export interface AdotCollectorProps {
|
|
|
35
36
|
iamRoleArn?: string;
|
|
36
37
|
/** Per-member defaults for fine-grained overrides. */
|
|
37
38
|
defaults?: {
|
|
38
|
-
daemonSet?:
|
|
39
|
-
serviceAccount?:
|
|
40
|
-
clusterRole?:
|
|
41
|
-
clusterRoleBinding?:
|
|
42
|
-
configMap?:
|
|
39
|
+
daemonSet?: MemberDefaults<"DaemonSet">;
|
|
40
|
+
serviceAccount?: MemberDefaults<"ServiceAccount">;
|
|
41
|
+
clusterRole?: MemberDefaults<"ClusterRole">;
|
|
42
|
+
clusterRoleBinding?: MemberDefaults<"ClusterRoleBinding">;
|
|
43
|
+
configMap?: MemberDefaults<"ConfigMap">;
|
|
43
44
|
};
|
|
44
45
|
}
|
|
45
46
|
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { Composite, mergeDefaults } from "@intentius/chant";
|
|
9
9
|
import { Ingress } from "../generated";
|
|
10
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
10
11
|
|
|
11
12
|
export interface AgicIngressHost {
|
|
12
13
|
/** Hostname (e.g., "api.example.com"). */
|
|
@@ -45,7 +46,7 @@ export interface AgicIngressProps {
|
|
|
45
46
|
namespace?: string;
|
|
46
47
|
/** Per-member defaults for fine-grained overrides. */
|
|
47
48
|
defaults?: {
|
|
48
|
-
ingress?:
|
|
49
|
+
ingress?: MemberDefaults<"Ingress">;
|
|
49
50
|
};
|
|
50
51
|
}
|
|
51
52
|
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { Composite, mergeDefaults } from "@intentius/chant";
|
|
9
9
|
import { Deployment, ServiceAccount, ClusterRole, ClusterRoleBinding } from "../generated";
|
|
10
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
10
11
|
|
|
11
12
|
export interface AksExternalDnsAgentProps {
|
|
12
13
|
/** Azure managed identity client ID for Workload Identity. */
|
|
@@ -33,10 +34,10 @@ export interface AksExternalDnsAgentProps {
|
|
|
33
34
|
labels?: Record<string, string>;
|
|
34
35
|
/** Per-member defaults for fine-grained overrides. */
|
|
35
36
|
defaults?: {
|
|
36
|
-
deployment?:
|
|
37
|
-
serviceAccount?:
|
|
38
|
-
clusterRole?:
|
|
39
|
-
clusterRoleBinding?:
|
|
37
|
+
deployment?: MemberDefaults<"Deployment">;
|
|
38
|
+
serviceAccount?: MemberDefaults<"ServiceAccount">;
|
|
39
|
+
clusterRole?: MemberDefaults<"ClusterRole">;
|
|
40
|
+
clusterRoleBinding?: MemberDefaults<"ClusterRoleBinding">;
|
|
40
41
|
};
|
|
41
42
|
}
|
|
42
43
|
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { Composite, mergeDefaults } from "@intentius/chant";
|
|
9
9
|
import { Ingress } from "../generated";
|
|
10
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
10
11
|
|
|
11
12
|
export interface AlbIngressHost {
|
|
12
13
|
/** Hostname (e.g., "api.example.com"). */
|
|
@@ -48,7 +49,7 @@ export interface AlbIngressProps {
|
|
|
48
49
|
namespace?: string;
|
|
49
50
|
/** Per-member defaults for fine-grained overrides. */
|
|
50
51
|
defaults?: {
|
|
51
|
-
ingress?:
|
|
52
|
+
ingress?: MemberDefaults<"Ingress">;
|
|
52
53
|
};
|
|
53
54
|
}
|
|
54
55
|
|
|
@@ -17,6 +17,7 @@ import {
|
|
|
17
17
|
ApplicationSet as ApplicationSetResource,
|
|
18
18
|
Secret as SecretResource,
|
|
19
19
|
} from "../generated";
|
|
20
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
20
21
|
|
|
21
22
|
// ── Shared types ─────────────────────────────────────────────────────────────
|
|
22
23
|
|
|
@@ -94,7 +95,7 @@ export interface ArgoAppForOptions {
|
|
|
94
95
|
syncPolicy?: ArgoSyncPolicy;
|
|
95
96
|
/** Extra labels applied to the Application. */
|
|
96
97
|
labels?: Record<string, string>;
|
|
97
|
-
defaults?: { application?:
|
|
98
|
+
defaults?: { application?: MemberDefaults<"Application"> };
|
|
98
99
|
}
|
|
99
100
|
|
|
100
101
|
export type ArgoAppForResult = {
|
|
@@ -193,7 +194,7 @@ export interface ArgoAppSetForRegionsOptions {
|
|
|
193
194
|
syncPolicy?: ArgoSyncPolicy;
|
|
194
195
|
/** Extra labels applied to the ApplicationSet. */
|
|
195
196
|
labels?: Record<string, string>;
|
|
196
|
-
defaults?: { applicationSet?:
|
|
197
|
+
defaults?: { applicationSet?: MemberDefaults<"ApplicationSet"> };
|
|
197
198
|
}
|
|
198
199
|
|
|
199
200
|
export type ArgoAppSetForRegionsResult = {
|
|
@@ -321,7 +322,7 @@ export interface RegisterArgoClusterOptions {
|
|
|
321
322
|
argoNamespace?: string;
|
|
322
323
|
/** Extra labels (merged with the required secret-type label). */
|
|
323
324
|
labels?: Record<string, string>;
|
|
324
|
-
defaults?: { secret?:
|
|
325
|
+
defaults?: { secret?: MemberDefaults<"Secret"> };
|
|
325
326
|
}
|
|
326
327
|
|
|
327
328
|
export type RegisterArgoClusterResult = {
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
import { Composite, mergeDefaults } from "@intentius/chant";
|
|
10
10
|
import { Deployment, Service, HorizontalPodAutoscaler, PodDisruptionBudget } from "../generated";
|
|
11
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
11
12
|
import type { ContainerSecurityContext } from "./security-context";
|
|
12
13
|
|
|
13
14
|
export interface AutoscaledServiceProps {
|
|
@@ -73,10 +74,10 @@ export interface AutoscaledServiceProps {
|
|
|
73
74
|
tmpDirs?: string[];
|
|
74
75
|
/** Per-member defaults for fine-grained overrides. */
|
|
75
76
|
defaults?: {
|
|
76
|
-
deployment?:
|
|
77
|
-
service?:
|
|
78
|
-
hpa?:
|
|
79
|
-
pdb?:
|
|
77
|
+
deployment?: MemberDefaults<"Deployment">;
|
|
78
|
+
service?: MemberDefaults<"Service">;
|
|
79
|
+
hpa?: MemberDefaults<"HorizontalPodAutoscaler">;
|
|
80
|
+
pdb?: MemberDefaults<"PodDisruptionBudget">;
|
|
80
81
|
};
|
|
81
82
|
}
|
|
82
83
|
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
import { Composite, mergeDefaults } from "@intentius/chant";
|
|
8
8
|
import { StorageClass } from "../generated";
|
|
9
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
9
10
|
|
|
10
11
|
export interface AzureDiskStorageClassProps {
|
|
11
12
|
/** StorageClass name. */
|
|
@@ -26,7 +27,7 @@ export interface AzureDiskStorageClassProps {
|
|
|
26
27
|
labels?: Record<string, string>;
|
|
27
28
|
/** Per-member defaults for fine-grained overrides. */
|
|
28
29
|
defaults?: {
|
|
29
|
-
storageClass?:
|
|
30
|
+
storageClass?: MemberDefaults<"StorageClass">;
|
|
30
31
|
};
|
|
31
32
|
}
|
|
32
33
|
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { Composite, mergeDefaults } from "@intentius/chant";
|
|
9
9
|
import { StorageClass } from "../generated";
|
|
10
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
10
11
|
|
|
11
12
|
export interface AzureFileStorageClassProps {
|
|
12
13
|
/** StorageClass name. */
|
|
@@ -23,7 +24,7 @@ export interface AzureFileStorageClassProps {
|
|
|
23
24
|
labels?: Record<string, string>;
|
|
24
25
|
/** Per-member defaults for fine-grained overrides. */
|
|
25
26
|
defaults?: {
|
|
26
|
-
storageClass?:
|
|
27
|
+
storageClass?: MemberDefaults<"StorageClass">;
|
|
27
28
|
};
|
|
28
29
|
}
|
|
29
30
|
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { Composite, mergeDefaults } from "@intentius/chant";
|
|
9
9
|
import { DaemonSet, ServiceAccount, ClusterRole, ClusterRoleBinding, ConfigMap } from "../generated";
|
|
10
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
10
11
|
|
|
11
12
|
export interface AzureMonitorCollectorProps {
|
|
12
13
|
/** Azure Log Analytics workspace ID. */
|
|
@@ -33,11 +34,11 @@ export interface AzureMonitorCollectorProps {
|
|
|
33
34
|
clientId?: string;
|
|
34
35
|
/** Per-member defaults for fine-grained overrides. */
|
|
35
36
|
defaults?: {
|
|
36
|
-
daemonSet?:
|
|
37
|
-
serviceAccount?:
|
|
38
|
-
clusterRole?:
|
|
39
|
-
clusterRoleBinding?:
|
|
40
|
-
configMap?:
|
|
37
|
+
daemonSet?: MemberDefaults<"DaemonSet">;
|
|
38
|
+
serviceAccount?: MemberDefaults<"ServiceAccount">;
|
|
39
|
+
clusterRole?: MemberDefaults<"ClusterRole">;
|
|
40
|
+
clusterRoleBinding?: MemberDefaults<"ClusterRoleBinding">;
|
|
41
|
+
configMap?: MemberDefaults<"ConfigMap">;
|
|
41
42
|
};
|
|
42
43
|
}
|
|
43
44
|
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
|
|
8
8
|
import { Composite, mergeDefaults } from "@intentius/chant";
|
|
9
9
|
import { Job, ServiceAccount, Role, RoleBinding } from "../generated";
|
|
10
|
+
import type { MemberDefaults } from "./member-defaults";
|
|
10
11
|
import type { ContainerSecurityContext } from "./security-context";
|
|
11
12
|
|
|
12
13
|
/** Parse a K8s memory string (e.g. "256Mi", "1Gi") to bytes for comparison. */
|
|
@@ -72,10 +73,10 @@ export interface BatchJobProps {
|
|
|
72
73
|
securityContext?: ContainerSecurityContext;
|
|
73
74
|
/** Per-member defaults for fine-grained overrides. */
|
|
74
75
|
defaults?: {
|
|
75
|
-
job?:
|
|
76
|
-
serviceAccount?:
|
|
77
|
-
role?:
|
|
78
|
-
roleBinding?:
|
|
76
|
+
job?: MemberDefaults<"Job">;
|
|
77
|
+
serviceAccount?: MemberDefaults<"ServiceAccount">;
|
|
78
|
+
role?: MemberDefaults<"Role">;
|
|
79
|
+
roleBinding?: MemberDefaults<"RoleBinding">;
|
|
79
80
|
};
|
|
80
81
|
}
|
|
81
82
|
|