@intentius/chant-lexicon-helm 0.7.0 → 0.8.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.
Files changed (138) hide show
  1. package/dist/codegen/docs-cli.d.ts +3 -0
  2. package/dist/codegen/docs-cli.d.ts.map +1 -0
  3. package/dist/codegen/docs.d.ts +9 -0
  4. package/dist/codegen/docs.d.ts.map +1 -0
  5. package/dist/codegen/generate-cli.d.ts +6 -0
  6. package/dist/codegen/generate-cli.d.ts.map +1 -0
  7. package/dist/codegen/generate.d.ts +22 -0
  8. package/dist/codegen/generate.d.ts.map +1 -0
  9. package/dist/codegen/naming.d.ts +13 -0
  10. package/dist/codegen/naming.d.ts.map +1 -0
  11. package/dist/codegen/package.d.ts +11 -0
  12. package/dist/codegen/package.d.ts.map +1 -0
  13. package/dist/composites/helm-batch-job.d.ts +58 -0
  14. package/dist/composites/helm-batch-job.d.ts.map +1 -0
  15. package/dist/composites/helm-crd-lifecycle.d.ts +41 -0
  16. package/dist/composites/helm-crd-lifecycle.d.ts.map +1 -0
  17. package/dist/composites/helm-cron-job.d.ts +57 -0
  18. package/dist/composites/helm-cron-job.d.ts.map +1 -0
  19. package/dist/composites/helm-daemon-set.d.ts +42 -0
  20. package/dist/composites/helm-daemon-set.d.ts.map +1 -0
  21. package/dist/composites/helm-external-secret.d.ts +36 -0
  22. package/dist/composites/helm-external-secret.d.ts.map +1 -0
  23. package/dist/composites/helm-library.d.ts +33 -0
  24. package/dist/composites/helm-library.d.ts.map +1 -0
  25. package/dist/composites/helm-microservice.d.ts +69 -0
  26. package/dist/composites/helm-microservice.d.ts.map +1 -0
  27. package/dist/composites/helm-monitored-service.d.ts +64 -0
  28. package/dist/composites/helm-monitored-service.d.ts.map +1 -0
  29. package/dist/composites/helm-namespace-env.d.ts +38 -0
  30. package/dist/composites/helm-namespace-env.d.ts.map +1 -0
  31. package/dist/composites/helm-secure-ingress.d.ts +32 -0
  32. package/dist/composites/helm-secure-ingress.d.ts.map +1 -0
  33. package/dist/composites/helm-stateful-service.d.ts +61 -0
  34. package/dist/composites/helm-stateful-service.d.ts.map +1 -0
  35. package/dist/composites/helm-web-app.d.ts +67 -0
  36. package/dist/composites/helm-web-app.d.ts.map +1 -0
  37. package/dist/composites/helm-worker.d.ts +42 -0
  38. package/dist/composites/helm-worker.d.ts.map +1 -0
  39. package/dist/composites/index.d.ts +27 -0
  40. package/dist/composites/index.d.ts.map +1 -0
  41. package/dist/coverage.d.ts +14 -0
  42. package/dist/coverage.d.ts.map +1 -0
  43. package/dist/detect.d.ts +3 -0
  44. package/dist/detect.d.ts.map +1 -0
  45. package/dist/generated/index.d.ts +9 -0
  46. package/dist/generated/index.d.ts.map +1 -0
  47. package/dist/helpers.d.ts +17 -0
  48. package/dist/helpers.d.ts.map +1 -0
  49. package/dist/import/generator.d.ts +30 -0
  50. package/dist/import/generator.d.ts.map +1 -0
  51. package/dist/import/parser.d.ts +21 -0
  52. package/dist/import/parser.d.ts.map +1 -0
  53. package/dist/import/template-stripper.d.ts +40 -0
  54. package/dist/import/template-stripper.d.ts.map +1 -0
  55. package/dist/index.d.ts +22 -0
  56. package/dist/index.d.ts.map +1 -0
  57. package/dist/integrity.json +2 -2
  58. package/dist/intrinsics.d.ts +260 -0
  59. package/dist/intrinsics.d.ts.map +1 -0
  60. package/dist/lint/post-synth/helm-helpers.d.ts +26 -0
  61. package/dist/lint/post-synth/helm-helpers.d.ts.map +1 -0
  62. package/dist/lint/post-synth/index.d.ts +3 -0
  63. package/dist/lint/post-synth/index.d.ts.map +1 -0
  64. package/dist/lint/post-synth/whm005-no-empty-wrapper.d.ts +14 -0
  65. package/dist/lint/post-synth/whm005-no-empty-wrapper.d.ts.map +1 -0
  66. package/dist/lint/post-synth/whm101.d.ts +6 -0
  67. package/dist/lint/post-synth/whm101.d.ts.map +1 -0
  68. package/dist/lint/post-synth/whm102.d.ts +6 -0
  69. package/dist/lint/post-synth/whm102.d.ts.map +1 -0
  70. package/dist/lint/post-synth/whm103.d.ts +6 -0
  71. package/dist/lint/post-synth/whm103.d.ts.map +1 -0
  72. package/dist/lint/post-synth/whm104.d.ts +6 -0
  73. package/dist/lint/post-synth/whm104.d.ts.map +1 -0
  74. package/dist/lint/post-synth/whm105.d.ts +6 -0
  75. package/dist/lint/post-synth/whm105.d.ts.map +1 -0
  76. package/dist/lint/post-synth/whm201.d.ts +6 -0
  77. package/dist/lint/post-synth/whm201.d.ts.map +1 -0
  78. package/dist/lint/post-synth/whm202.d.ts +6 -0
  79. package/dist/lint/post-synth/whm202.d.ts.map +1 -0
  80. package/dist/lint/post-synth/whm203.d.ts +10 -0
  81. package/dist/lint/post-synth/whm203.d.ts.map +1 -0
  82. package/dist/lint/post-synth/whm204.d.ts +6 -0
  83. package/dist/lint/post-synth/whm204.d.ts.map +1 -0
  84. package/dist/lint/post-synth/whm301.d.ts +6 -0
  85. package/dist/lint/post-synth/whm301.d.ts.map +1 -0
  86. package/dist/lint/post-synth/whm302.d.ts +6 -0
  87. package/dist/lint/post-synth/whm302.d.ts.map +1 -0
  88. package/dist/lint/post-synth/whm401.d.ts +9 -0
  89. package/dist/lint/post-synth/whm401.d.ts.map +1 -0
  90. package/dist/lint/post-synth/whm402.d.ts +9 -0
  91. package/dist/lint/post-synth/whm402.d.ts.map +1 -0
  92. package/dist/lint/post-synth/whm403.d.ts +9 -0
  93. package/dist/lint/post-synth/whm403.d.ts.map +1 -0
  94. package/dist/lint/post-synth/whm404.d.ts +6 -0
  95. package/dist/lint/post-synth/whm404.d.ts.map +1 -0
  96. package/dist/lint/post-synth/whm405.d.ts +9 -0
  97. package/dist/lint/post-synth/whm405.d.ts.map +1 -0
  98. package/dist/lint/post-synth/whm406.d.ts +8 -0
  99. package/dist/lint/post-synth/whm406.d.ts.map +1 -0
  100. package/dist/lint/post-synth/whm407.d.ts +9 -0
  101. package/dist/lint/post-synth/whm407.d.ts.map +1 -0
  102. package/dist/lint/post-synth/whm501.d.ts +10 -0
  103. package/dist/lint/post-synth/whm501.d.ts.map +1 -0
  104. package/dist/lint/post-synth/whm502.d.ts +9 -0
  105. package/dist/lint/post-synth/whm502.d.ts.map +1 -0
  106. package/dist/lint/rules/chart-metadata.d.ts +11 -0
  107. package/dist/lint/rules/chart-metadata.d.ts.map +1 -0
  108. package/dist/lint/rules/no-hardcoded-image.d.ts +14 -0
  109. package/dist/lint/rules/no-hardcoded-image.d.ts.map +1 -0
  110. package/dist/lint/rules/values-no-helm-tpl.d.ts +13 -0
  111. package/dist/lint/rules/values-no-helm-tpl.d.ts.map +1 -0
  112. package/dist/lint/rules/values-no-secrets.d.ts +13 -0
  113. package/dist/lint/rules/values-no-secrets.d.ts.map +1 -0
  114. package/dist/list-artifacts.d.ts +22 -0
  115. package/dist/list-artifacts.d.ts.map +1 -0
  116. package/dist/lsp/completions.d.ts +6 -0
  117. package/dist/lsp/completions.d.ts.map +1 -0
  118. package/dist/lsp/hover.d.ts +6 -0
  119. package/dist/lsp/hover.d.ts.map +1 -0
  120. package/dist/manifest.json +1 -1
  121. package/dist/package-cli.d.ts +6 -0
  122. package/dist/package-cli.d.ts.map +1 -0
  123. package/dist/plugin.d.ts +9 -0
  124. package/dist/plugin.d.ts.map +1 -0
  125. package/dist/render.d.ts +55 -0
  126. package/dist/render.d.ts.map +1 -0
  127. package/dist/resources.d.ts +102 -0
  128. package/dist/resources.d.ts.map +1 -0
  129. package/dist/serializer.d.ts +20 -0
  130. package/dist/serializer.d.ts.map +1 -0
  131. package/dist/validate-cli.d.ts +6 -0
  132. package/dist/validate-cli.d.ts.map +1 -0
  133. package/dist/validate.d.ts +15 -0
  134. package/dist/validate.d.ts.map +1 -0
  135. package/package.json +24 -5
  136. package/src/detect.ts +10 -0
  137. package/src/lint/post-synth/index.ts +47 -0
  138. package/src/plugin.ts +5 -12
@@ -0,0 +1 @@
1
+ {"version":3,"file":"values-no-helm-tpl.d.ts","sourceRoot":"","sources":["../../../src/lint/rules/values-no-helm-tpl.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAA+B,MAAM,4BAA4B,CAAC;AAGxF,eAAO,MAAM,mBAAmB,EAAE,QA8BjC,CAAC"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * WHM002: Values Should Not Contain Bare Secrets
3
+ *
4
+ * Detects Values constructor props that contain keys suggesting sensitive
5
+ * data (password, token, key, secret, apiKey) without an `existingSecret`
6
+ * pattern — hardcoded secrets in values.yaml are a security anti-pattern.
7
+ *
8
+ * Bad: new Values({ dbPassword: "hunter2" })
9
+ * Good: new Values({ existingSecret: "", dbPasswordKey: "password" })
10
+ */
11
+ import type { LintRule } from "@intentius/chant/lint/rule";
12
+ export declare const valuesNoSecretsRule: LintRule;
13
+ //# sourceMappingURL=values-no-secrets.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"values-no-secrets.d.ts","sourceRoot":"","sources":["../../../src/lint/rules/values-no-secrets.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAA+B,MAAM,4BAA4B,CAAC;AAMxF,eAAO,MAAM,mBAAmB,EAAE,QA+BjC,CAAC"}
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Live introspection of Helm releases via `helm list -A -o json`.
3
+ *
4
+ * The Helm lexicon's chant entities describe chart-authoring primitives
5
+ * (Chart.yaml, templates/, values.yaml). The runtime concept — a Helm
6
+ * release installed in a kubeconfig context — is created by `helm install`
7
+ * outside chant's entity model. This implementation reports those releases
8
+ * as artifacts so `state diff --live` / `WatchOp` can detect manual
9
+ * installs/upgrades/rollbacks that slip past CI.
10
+ *
11
+ * Helm-not-installed (binary missing) → returns `{}` cleanly so other
12
+ * lexicons' snapshots aren't blocked.
13
+ */
14
+ import type { ArtifactMetadata } from "@intentius/chant/lexicon";
15
+ export declare function listArtifacts(_options: {
16
+ environment: string;
17
+ entities: Map<string, {
18
+ entityType: string;
19
+ props: Record<string, unknown>;
20
+ }>;
21
+ }): Promise<Record<string, ArtifactMetadata>>;
22
+ //# sourceMappingURL=list-artifacts.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"list-artifacts.d.ts","sourceRoot":"","sources":["../src/list-artifacts.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAIH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAsBjE,wBAAsB,aAAa,CAAC,QAAQ,EAAE;IAC5C,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE;QAAE,UAAU,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;KAAE,CAAC,CAAC;CAC/E,GAAG,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,gBAAgB,CAAC,CAAC,CAqC5C"}
@@ -0,0 +1,6 @@
1
+ import type { CompletionContext, CompletionItem } from "@intentius/chant/lsp/types";
2
+ /**
3
+ * Provide Helm resource completions based on context.
4
+ */
5
+ export declare function helmCompletions(ctx: CompletionContext): CompletionItem[];
6
+ //# sourceMappingURL=completions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"completions.d.ts","sourceRoot":"","sources":["../../src/lsp/completions.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAapF;;GAEG;AACH,wBAAgB,eAAe,CAAC,GAAG,EAAE,iBAAiB,GAAG,cAAc,EAAE,CAExE"}
@@ -0,0 +1,6 @@
1
+ import type { HoverContext, HoverInfo } from "@intentius/chant/lsp/types";
2
+ /**
3
+ * Provide hover information for Helm resource types.
4
+ */
5
+ export declare function helmHover(ctx: HoverContext): HoverInfo | undefined;
6
+ //# sourceMappingURL=hover.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hover.d.ts","sourceRoot":"","sources":["../../src/lsp/hover.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AAa1E;;GAEG;AACH,wBAAgB,SAAS,CAAC,GAAG,EAAE,YAAY,GAAG,SAAS,GAAG,SAAS,CAElE"}
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "helm",
3
- "version": "0.7.0",
3
+ "version": "0.8.0",
4
4
  "chantVersion": ">=0.1.0",
5
5
  "namespace": "Helm",
6
6
  "intrinsics": [
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env tsx
2
+ /**
3
+ * CLI entry point for Helm lexicon packaging.
4
+ */
5
+ export {};
6
+ //# sourceMappingURL=package-cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"package-cli.d.ts","sourceRoot":"","sources":["../src/package-cli.ts"],"names":[],"mappings":";AACA;;GAEG"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Helm lexicon plugin.
3
+ *
4
+ * Implements the LexiconPlugin interface with the Helm chart serializer,
5
+ * Helm-specific intrinsics, lint rules, and post-synth checks.
6
+ */
7
+ import type { LexiconPlugin } from "@intentius/chant/lexicon";
8
+ export declare const helmPlugin: LexiconPlugin;
9
+ //# sourceMappingURL=plugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"plugin.d.ts","sourceRoot":"","sources":["../src/plugin.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,KAAK,EAAE,aAAa,EAAiC,MAAM,0BAA0B,CAAC;AAS7F,eAAO,MAAM,UAAU,EAAE,aAsWxB,CAAC"}
@@ -0,0 +1,55 @@
1
+ /**
2
+ * HelmRender — render an upstream Helm chart at chant build time.
3
+ *
4
+ * Most chant projects that want to install third-party operators (ESO,
5
+ * cert-manager, ingress-nginx, etc.) ran `helm template` or `helm install`
6
+ * as a separate deploy phase. That meant the chant build output was
7
+ * incomplete — `kubectl apply -f dist/...yaml` didn't carry those operators.
8
+ *
9
+ * `HelmRender({ repo, chart, version, values })` resolves at synth time:
10
+ * 1. Shells out to `helm template` (requires the `helm` binary in PATH).
11
+ * 2. Parses the resulting multi-document YAML.
12
+ * 3. Emits each rendered K8s manifest as a Declarable in the build output.
13
+ * 4. Caches the rendered output under `~/.chant/helm-renders/<hash>/`
14
+ * keyed by (repo, chart, version, values) so subsequent builds skip
15
+ * network access.
16
+ *
17
+ * The lexicon must include both `helm` and `k8s` (since rendered manifests
18
+ * are k8s resources).
19
+ *
20
+ * @example
21
+ * import { HelmRender } from "@intentius/chant-lexicon-helm";
22
+ *
23
+ * export const eso = HelmRender({
24
+ * name: "external-secrets",
25
+ * repo: "https://charts.external-secrets.io",
26
+ * chart: "external-secrets",
27
+ * version: "0.10.4",
28
+ * namespace: "external-secrets",
29
+ * createNamespace: true,
30
+ * values: { installCRDs: true },
31
+ * });
32
+ */
33
+ export interface HelmRenderProps {
34
+ /** Logical name for the render (used in cache key + composite name). */
35
+ name: string;
36
+ /** Chart repo URL, e.g. https://charts.external-secrets.io */
37
+ repo: string;
38
+ /** Chart name, e.g. "external-secrets" */
39
+ chart: string;
40
+ /** Pinned chart version, e.g. "0.10.4" */
41
+ version: string;
42
+ /** Target namespace passed to `helm template --namespace`. */
43
+ namespace?: string;
44
+ /** Also emit a Namespace manifest. Default: false. */
45
+ createNamespace?: boolean;
46
+ /** Helm values overrides (written to a values.yaml then passed via -f). */
47
+ values?: Record<string, unknown>;
48
+ /**
49
+ * Skip the on-disk cache. Default: false. Tests pass `true` to force a
50
+ * fresh render.
51
+ */
52
+ noCache?: boolean;
53
+ }
54
+ export declare const HelmRender: import("@intentius/chant").CompositeDefinition<HelmRenderProps, import("@intentius/chant").CompositeMembers>;
55
+ //# sourceMappingURL=render.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"render.d.ts","sourceRoot":"","sources":["../src/render.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAeH,MAAM,WAAW,eAAe;IAC9B,wEAAwE;IACxE,IAAI,EAAE,MAAM,CAAC;IACb,8DAA8D;IAC9D,IAAI,EAAE,MAAM,CAAC;IACb,0CAA0C;IAC1C,KAAK,EAAE,MAAM,CAAC;IACd,0CAA0C;IAC1C,OAAO,EAAE,MAAM,CAAC;IAChB,8DAA8D;IAC9D,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sDAAsD;IACtD,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,2EAA2E;IAC3E,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACjC;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAoHD,eAAO,MAAM,UAAU,8GA8BP,CAAC"}
@@ -0,0 +1,102 @@
1
+ /**
2
+ * Helm-specific resource and property types.
3
+ *
4
+ * Created via createResource/createProperty from @intentius/chant/runtime.
5
+ * These are static types (no upstream schema to fetch).
6
+ */
7
+ /**
8
+ * Helm::Chart — Chart.yaml metadata.
9
+ *
10
+ * Defines the chart's identity: apiVersion, name, version, appVersion,
11
+ * description, type (application|library), keywords, maintainers, dependencies.
12
+ */
13
+ export declare const Chart: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
14
+ /**
15
+ * Helm::Values — Typed values definition.
16
+ *
17
+ * The props passed to the constructor become the default values emitted
18
+ * in values.yaml. The serializer also generates values.schema.json from
19
+ * the value types.
20
+ */
21
+ export declare const Values: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
22
+ /**
23
+ * Helm::Test — Helm test pod.
24
+ *
25
+ * Annotated with `helm.sh/hook: test` in the serialized output.
26
+ * Props should contain a K8s Pod spec.
27
+ */
28
+ export declare const HelmTest: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
29
+ /**
30
+ * Helm::Notes — NOTES.txt template content.
31
+ *
32
+ * The `content` prop is emitted as templates/NOTES.txt.
33
+ */
34
+ export declare const HelmNotes: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
35
+ /**
36
+ * Helm::Hook — Lifecycle hook annotation.
37
+ *
38
+ * Wraps a K8s resource with helm.sh/hook annotations.
39
+ * Props: { hook: string, weight?: number, deletePolicy?: string, resource: Declarable }
40
+ */
41
+ export declare const HelmHook: new (props: Record<string, unknown>) => Record<string, unknown>;
42
+ /**
43
+ * Helm::Dependency — Chart dependency entry.
44
+ *
45
+ * Props: { name, version, repository, condition?, tags?, enabled?, importValues?, alias? }
46
+ */
47
+ export declare const HelmDependency: new (props: Record<string, unknown>) => Record<string, unknown>;
48
+ /**
49
+ * Helm::Maintainer — Chart maintainer entry.
50
+ *
51
+ * Props: { name, email?, url? }
52
+ */
53
+ export declare const HelmMaintainer: new (props: Record<string, unknown>) => Record<string, unknown>;
54
+ /**
55
+ * Helm::ValuesOverride — Generate a named YAML override file.
56
+ *
57
+ * Emits a standalone YAML file inside the chart directory, intended to be
58
+ * passed as `helm upgrade -f chart-dir/values-base.yaml`. Use this for
59
+ * static configuration shared across all deployments (disabled bundled
60
+ * services, shared secret references, etc.).
61
+ *
62
+ * Props: { filename: string, values: Record<string, unknown> }
63
+ *
64
+ * ```ts
65
+ * new ValuesOverride({
66
+ * filename: "values-base",
67
+ * values: { postgresql: { install: false }, redis: { install: false } },
68
+ * })
69
+ * // → generates chart-dir/values-base.yaml
70
+ * ```
71
+ */
72
+ export declare const ValuesOverride: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
73
+ /**
74
+ * Helm::CRD — Custom Resource Definition placed in the crds/ directory.
75
+ *
76
+ * Props: { content: string, filename?: string }
77
+ */
78
+ export declare const HelmCRD: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
79
+ export declare const Deployment: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
80
+ export declare const StatefulSet: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
81
+ export declare const DaemonSet: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
82
+ export declare const Service: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
83
+ export declare const ServiceAccount: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
84
+ export declare const ConfigMap: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
85
+ export declare const Namespace: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
86
+ export declare const Job: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
87
+ export declare const CronJob: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
88
+ export declare const Ingress: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
89
+ export declare const NetworkPolicy: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
90
+ export declare const HPA: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
91
+ export declare const PDB: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
92
+ export declare const ResourceQuota: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
93
+ export declare const LimitRange: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
94
+ export declare const ClusterRole: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
95
+ export declare const ClusterRoleBinding: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
96
+ export declare const Role: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
97
+ export declare const RoleBinding: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
98
+ export declare const ExternalSecret: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
99
+ export declare const ServiceMonitor: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
100
+ export declare const PrometheusRule: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
101
+ export declare const Certificate: new (props: Record<string, unknown>, attributes?: Record<string, unknown>) => import("packages/core/src").Declarable & Record<string, string>;
102
+ //# sourceMappingURL=resources.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"resources.d.ts","sourceRoot":"","sources":["../src/resources.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAQH;;;;;GAKG;AACH,eAAO,MAAM,KAAK,+IAA6C,CAAC;AAEhE;;;;;;GAMG;AACH,eAAO,MAAM,MAAM,+IAA8C,CAAC;AAElE;;;;;GAKG;AACH,eAAO,MAAM,QAAQ,+IAA4C,CAAC;AAElE;;;;GAIG;AACH,eAAO,MAAM,SAAS,+IAA6C,CAAC;AAIpE;;;;;GAKG;AACH,eAAO,MAAM,QAAQ,iEAAwC,CAAC;AAE9D;;;;GAIG;AACH,eAAO,MAAM,cAAc,iEAA8C,CAAC;AAE1E;;;;GAIG;AACH,eAAO,MAAM,cAAc,iEAA8C,CAAC;AAE1E;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,cAAc,+IAAsD,CAAC;AAIlF;;;;GAIG;AACH,eAAO,MAAM,OAAO,+IAA2C,CAAC;AAOhE,eAAO,MAAM,UAAU,+IAAmD,CAAC;AAC3E,eAAO,MAAM,WAAW,+IAAoD,CAAC;AAC7E,eAAO,MAAM,SAAS,+IAAkD,CAAC;AACzE,eAAO,MAAM,OAAO,+IAAgD,CAAC;AACrE,eAAO,MAAM,cAAc,+IAAuD,CAAC;AACnF,eAAO,MAAM,SAAS,+IAAkD,CAAC;AACzE,eAAO,MAAM,SAAS,+IAAkD,CAAC;AACzE,eAAO,MAAM,GAAG,+IAA6C,CAAC;AAC9D,eAAO,MAAM,OAAO,+IAAiD,CAAC;AACtE,eAAO,MAAM,OAAO,+IAAsD,CAAC;AAC3E,eAAO,MAAM,aAAa,+IAA4D,CAAC;AACvF,eAAO,MAAM,GAAG,+IAAuE,CAAC;AACxF,eAAO,MAAM,GAAG,+IAA8D,CAAC;AAC/E,eAAO,MAAM,aAAa,+IAAsD,CAAC;AACjF,eAAO,MAAM,UAAU,+IAAmD,CAAC;AAC3E,eAAO,MAAM,WAAW,+IAAoD,CAAC;AAC7E,eAAO,MAAM,kBAAkB,+IAA2D,CAAC;AAC3F,eAAO,MAAM,IAAI,+IAA6C,CAAC;AAC/D,eAAO,MAAM,WAAW,+IAAoD,CAAC;AAC7E,eAAO,MAAM,cAAc,+IAAkE,CAAC;AAC9F,eAAO,MAAM,cAAc,+IAA6D,CAAC;AACzF,eAAO,MAAM,cAAc,+IAA6D,CAAC;AACzF,eAAO,MAAM,WAAW,+IAA2D,CAAC"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Helm chart serializer.
3
+ *
4
+ * Converts Chant declarables into a complete Helm chart directory structure
5
+ * returned as a SerializerResult with a files map:
6
+ *
7
+ * Chart.yaml, values.yaml, values.schema.json, .helmignore,
8
+ * templates/_helpers.tpl, templates/<resource>.yaml, templates/NOTES.txt,
9
+ * templates/tests/test-connection.yaml
10
+ *
11
+ * The serializer detects `__helm_tpl` markers in walked values and emits
12
+ * raw Go template expressions instead of YAML-quoting them. It also
13
+ * detects `__helm_if` markers to wrap entire resources in conditionals.
14
+ */
15
+ import type { Serializer } from "@intentius/chant/serializer";
16
+ /**
17
+ * Helm chart serializer implementation.
18
+ */
19
+ export declare const helmSerializer: Serializer;
20
+ //# sourceMappingURL=serializer.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serializer.d.ts","sourceRoot":"","sources":["../src/serializer.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAKH,OAAO,KAAK,EAAE,UAAU,EAAoB,MAAM,6BAA6B,CAAC;AAitBhF;;GAEG;AACH,eAAO,MAAM,cAAc,EAAE,UAoO5B,CAAC"}
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env tsx
2
+ /**
3
+ * CLI entry point for Helm lexicon validation.
4
+ */
5
+ export {};
6
+ //# sourceMappingURL=validate-cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validate-cli.d.ts","sourceRoot":"","sources":["../src/validate-cli.ts"],"names":[],"mappings":";AACA;;GAEG"}
@@ -0,0 +1,15 @@
1
+ /**
2
+ * Validate generated lexicon-helm artifacts.
3
+ *
4
+ * Thin wrapper around the core validation framework
5
+ * with Helm-specific configuration.
6
+ */
7
+ import { type ValidateResult } from "@intentius/chant/codegen/validate";
8
+ export type { ValidateCheck, ValidateResult } from "@intentius/chant/codegen/validate";
9
+ /**
10
+ * Validate the generated lexicon-helm artifacts.
11
+ */
12
+ export declare function validate(opts?: {
13
+ basePath?: string;
14
+ }): Promise<ValidateResult>;
15
+ //# sourceMappingURL=validate.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"validate.d.ts","sourceRoot":"","sources":["../src/validate.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH,OAAO,EAA4B,KAAK,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAElG,YAAY,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAavF;;GAEG;AACH,wBAAsB,QAAQ,CAAC,IAAI,CAAC,EAAE;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAE,GAAG,OAAO,CAAC,cAAc,CAAC,CAQpF"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@intentius/chant-lexicon-helm",
3
- "version": "0.7.0",
3
+ "version": "0.8.0",
4
4
  "description": "Helm chart lexicon for chant — declarative IaC in TypeScript",
5
5
  "license": "Apache-2.0",
6
6
  "homepage": "https://intentius.io/chant",
@@ -29,8 +29,26 @@
29
29
  "access": "public"
30
30
  },
31
31
  "exports": {
32
- ".": "./src/index.ts",
33
- "./*": "./src/*.ts",
32
+ ".": {
33
+ "development": "./src/index.ts",
34
+ "types": "./dist/index.d.ts",
35
+ "default": "./src/index.ts"
36
+ },
37
+ "./*": {
38
+ "development": "./src/*.ts",
39
+ "types": "./dist/*.d.ts",
40
+ "default": "./src/*.ts"
41
+ },
42
+ "./detect": {
43
+ "development": "./src/detect.ts",
44
+ "types": "./dist/detect.d.ts",
45
+ "default": "./src/detect.ts"
46
+ },
47
+ "./lint/post-synth": {
48
+ "development": "./src/lint/post-synth/index.ts",
49
+ "types": "./dist/lint/post-synth/index.d.ts",
50
+ "default": "./src/lint/post-synth/index.ts"
51
+ },
34
52
  "./manifest": "./dist/manifest.json",
35
53
  "./meta": "./dist/meta.json",
36
54
  "./types": "./dist/types/index.d.ts"
@@ -40,7 +58,8 @@
40
58
  "bundle": "tsx src/package-cli.ts",
41
59
  "validate": "tsx src/validate-cli.ts",
42
60
  "docs": "tsx src/codegen/docs-cli.ts",
43
- "prepack": "npm run generate && npm run bundle && npm run validate"
61
+ "prepack": "npm run generate && npm run bundle && npm run validate && npm run build",
62
+ "build": "tsc -p tsconfig.build.json && tsc-alias -p tsconfig.build.json && find dist -type f \\( -name \"*.js\" -o -name \"*.js.map\" \\) -delete"
44
63
  },
45
64
  "dependencies": {
46
65
  "@intentius/chant-lexicon-k8s": "*"
@@ -50,6 +69,6 @@
50
69
  "typescript": "^5.9.3"
51
70
  },
52
71
  "peerDependencies": {
53
- "@intentius/chant": "^0.1.0"
72
+ "@intentius/chant": "^0.8.0"
54
73
  }
55
74
  }
package/src/detect.ts ADDED
@@ -0,0 +1,10 @@
1
+ /** Edge-safe template detection for helm (Chart.yaml) — see #426. */
2
+ export function detectTemplate(data: unknown): boolean {
3
+ if (typeof data !== "object" || data === null) return false;
4
+ const obj = data as Record<string, unknown>;
5
+ // Helm charts have apiVersion: v2 in Chart.yaml
6
+ if (obj.apiVersion === "v2" && typeof obj.name === "string" && typeof obj.version === "string") {
7
+ return true;
8
+ }
9
+ return false;
10
+ }
@@ -0,0 +1,47 @@
1
+ // Code generated by chant generate. DO NOT EDIT.
2
+ import type { PostSynthCheck } from "@intentius/chant/lint/post-synth";
3
+ import { whm005 } from "./whm005-no-empty-wrapper";
4
+ import { whm101 } from "./whm101";
5
+ import { whm102 } from "./whm102";
6
+ import { whm103 } from "./whm103";
7
+ import { whm104 } from "./whm104";
8
+ import { whm105 } from "./whm105";
9
+ import { whm201 } from "./whm201";
10
+ import { whm202 } from "./whm202";
11
+ import { whm203 } from "./whm203";
12
+ import { whm204 } from "./whm204";
13
+ import { whm301 } from "./whm301";
14
+ import { whm302 } from "./whm302";
15
+ import { whm401 } from "./whm401";
16
+ import { whm402 } from "./whm402";
17
+ import { whm403 } from "./whm403";
18
+ import { whm404 } from "./whm404";
19
+ import { whm405 } from "./whm405";
20
+ import { whm406 } from "./whm406";
21
+ import { whm407 } from "./whm407";
22
+ import { whm501 } from "./whm501";
23
+ import { whm502 } from "./whm502";
24
+
25
+ export const postSynthChecks: PostSynthCheck[] = [
26
+ whm005,
27
+ whm101,
28
+ whm102,
29
+ whm103,
30
+ whm104,
31
+ whm105,
32
+ whm201,
33
+ whm202,
34
+ whm203,
35
+ whm204,
36
+ whm301,
37
+ whm302,
38
+ whm401,
39
+ whm402,
40
+ whm403,
41
+ whm404,
42
+ whm405,
43
+ whm406,
44
+ whm407,
45
+ whm501,
46
+ whm502,
47
+ ];
package/src/plugin.ts CHANGED
@@ -6,7 +6,9 @@
6
6
  */
7
7
 
8
8
  import type { LexiconPlugin, IntrinsicDef, InitTemplateSet } from "@intentius/chant/lexicon";
9
- import { discoverLintRules, discoverPostSynthChecks } from "@intentius/chant/lint/discover";
9
+ import { detectTemplate } from "./detect";
10
+ import { discoverLintRules } from "@intentius/chant/lint/discover";
11
+ import { postSynthChecks as postSynthCheckList } from "./lint/post-synth";
10
12
  import { createSkillsLoader, createDiffTool } from "@intentius/chant/lexicon-plugin-helpers";
11
13
  import { join, dirname } from "path";
12
14
  import { fileURLToPath } from "url";
@@ -22,8 +24,7 @@ export const helmPlugin: LexiconPlugin = {
22
24
  },
23
25
 
24
26
  postSynthChecks() {
25
- const postSynthDir = join(dirname(fileURLToPath(import.meta.url)), "lint", "post-synth");
26
- return discoverPostSynthChecks(postSynthDir, import.meta.url);
27
+ return postSynthCheckList;
27
28
  },
28
29
 
29
30
  intrinsics(): IntrinsicDef[] {
@@ -54,15 +55,7 @@ export const helmPlugin: LexiconPlugin = {
54
55
  ];
55
56
  },
56
57
 
57
- detectTemplate(data: unknown): boolean {
58
- if (typeof data !== "object" || data === null) return false;
59
- const obj = data as Record<string, unknown>;
60
- // Helm charts have apiVersion: v2 in Chart.yaml
61
- if (obj.apiVersion === "v2" && typeof obj.name === "string" && typeof obj.version === "string") {
62
- return true;
63
- }
64
- return false;
65
- },
58
+ detectTemplate,
66
59
 
67
60
  mcpTools() {
68
61
  return [createDiffTool(helmSerializer, "Compare current Helm chart build output against previous output", "helm")];