@cat-factory/contracts 0.96.0 → 0.98.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 (44) hide show
  1. package/dist/entities.d.ts +11 -0
  2. package/dist/entities.d.ts.map +1 -1
  3. package/dist/environments.d.ts +977 -67
  4. package/dist/environments.d.ts.map +1 -1
  5. package/dist/environments.js +13 -2
  6. package/dist/environments.js.map +1 -1
  7. package/dist/primitives.d.ts +61 -0
  8. package/dist/primitives.d.ts.map +1 -1
  9. package/dist/primitives.js +87 -0
  10. package/dist/primitives.js.map +1 -1
  11. package/dist/provider-config.d.ts +29 -5
  12. package/dist/provider-config.d.ts.map +1 -1
  13. package/dist/provider-config.js +33 -2
  14. package/dist/provider-config.js.map +1 -1
  15. package/dist/recurring.d.ts +3 -3
  16. package/dist/recurring.d.ts.map +1 -1
  17. package/dist/recurring.js +6 -1
  18. package/dist/recurring.js.map +1 -1
  19. package/dist/requests.d.ts +11 -0
  20. package/dist/requests.d.ts.map +1 -1
  21. package/dist/routes/board.d.ts +121 -0
  22. package/dist/routes/board.d.ts.map +1 -1
  23. package/dist/routes/environments.d.ts +601 -4
  24. package/dist/routes/environments.d.ts.map +1 -1
  25. package/dist/routes/execution.d.ts +22 -0
  26. package/dist/routes/execution.d.ts.map +1 -1
  27. package/dist/routes/initiative.d.ts +11 -0
  28. package/dist/routes/initiative.d.ts.map +1 -1
  29. package/dist/routes/recurring.d.ts +5 -5
  30. package/dist/routes/runners.d.ts +184 -2
  31. package/dist/routes/runners.d.ts.map +1 -1
  32. package/dist/routes/tasks.d.ts +33 -0
  33. package/dist/routes/tasks.d.ts.map +1 -1
  34. package/dist/routes/user-secret.d.ts +2 -2
  35. package/dist/routes/workspaces.d.ts +24 -2
  36. package/dist/routes/workspaces.d.ts.map +1 -1
  37. package/dist/runners.d.ts +292 -2
  38. package/dist/runners.d.ts.map +1 -1
  39. package/dist/runners.js +21 -3
  40. package/dist/runners.js.map +1 -1
  41. package/dist/snapshot.d.ts +12 -1
  42. package/dist/snapshot.d.ts.map +1 -1
  43. package/dist/user-secret.d.ts +1 -1
  44. package/package.json +1 -1
@@ -753,8 +753,194 @@ export declare const kubernetesProvisionConfigSchema: v.ObjectSchema<{
753
753
  }, undefined>], undefined>, undefined>, undefined>;
754
754
  }, undefined>;
755
755
  export type KubernetesProvisionConfig = v.InferOutput<typeof kubernetesProvisionConfigSchema>;
756
+ /**
757
+ * The AWS EKS provision config: the full Kubernetes provision config (an EKS apiserver is a
758
+ * standard apiserver, so per-PR namespaces + manifest apply are identical) PLUS the AWS
759
+ * `region` + `clusterName` needed to mint the IAM apiserver token. The AWS credentials ride
760
+ * the secret bundle; the SigV4/STS minting lives in `@cat-factory/eks`.
761
+ */
762
+ export declare const eksProvisionConfigSchema: v.ObjectSchema<{
763
+ readonly region: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be an AWS region slug">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
764
+ readonly clusterName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
765
+ readonly stsHost: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be a bare host or host:port">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>;
766
+ /** Human label for the connection (shown in the UI). */
767
+ readonly label: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
768
+ /** kube-apiserver root URL, e.g. `https://my-cluster.example:6443`. */
769
+ readonly apiServerUrl: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>;
770
+ /** PEM CA bundle to verify the apiserver TLS cert (omit only for a publicly-trusted CA). */
771
+ readonly caCertPem: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
772
+ /** Skip apiserver TLS verification — strongly discouraged; kind/dev clusters only. */
773
+ readonly insecureSkipTlsVerify: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
774
+ /**
775
+ * Namespace name template for the per-PR environment, e.g. `cf-env-{{pullNumber}}`.
776
+ * Rendered with the provision vars then sanitized to an RFC1123 label; absent ⇒ a
777
+ * default derived from the PR number / block id.
778
+ */
779
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 200, undefined>]>, undefined>;
780
+ /** Where the manifests are read from (co-located in the PR repo, or a separate repo). */
781
+ readonly manifestSource: v.VariantSchema<"type", [v.ObjectSchema<{
782
+ readonly type: v.LiteralSchema<"colocated", undefined>;
783
+ /** File or directory path within the PR repo (read at the PR head branch). */
784
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
785
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
786
+ }, undefined>, v.ObjectSchema<{
787
+ readonly type: v.LiteralSchema<"separate", undefined>;
788
+ /** `owner/repo` of the manifests repo. */
789
+ readonly repo: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be \"owner/repo\"">]>;
790
+ /** Branch/tag/sha to read at; absent ⇒ that repo's default branch. */
791
+ readonly ref: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
792
+ /** File or directory path within the manifests repo. */
793
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
794
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
795
+ }, undefined>], undefined>;
796
+ /** How the environment URL is derived once applied. */
797
+ readonly url: v.VariantSchema<"source", [v.ObjectSchema<{
798
+ readonly source: v.LiteralSchema<"ingressTemplate", undefined>;
799
+ /** Host template, e.g. `{{branch}}.preview.example.com`; rendered with the provision vars. */
800
+ readonly hostTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
801
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
802
+ }, undefined>, v.ObjectSchema<{
803
+ readonly source: v.LiteralSchema<"ingressStatus", undefined>;
804
+ /** Ingress object to read `.status.loadBalancer` from; absent ⇒ the only Ingress applied. */
805
+ readonly ingressName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
806
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
807
+ }, undefined>, v.ObjectSchema<{
808
+ readonly source: v.LiteralSchema<"serviceStatus", undefined>;
809
+ /** Service object to read `.status.loadBalancer` (k3s ServiceLB) from. */
810
+ readonly serviceName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
811
+ readonly port: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>, v.MaxValueAction<number, 65535, undefined>]>, undefined>;
812
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
813
+ }, undefined>, v.ObjectSchema<{
814
+ readonly source: v.LiteralSchema<"gatewayStatus", undefined>;
815
+ /** Gateway-API `Gateway` to read `.status.addresses[]` from; absent ⇒ the only one applied. */
816
+ readonly gatewayName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
817
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
818
+ }, undefined>, v.ObjectSchema<{
819
+ readonly source: v.LiteralSchema<"httpRouteStatus", undefined>;
820
+ /** `HTTPRoute` whose `parentRefs` resolve to the Gateway address; absent ⇒ the only one applied. */
821
+ readonly httpRouteName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
822
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
823
+ }, undefined>], undefined>;
824
+ /**
825
+ * Optional image reference made available to the manifests as `{{image}}` (e.g. a
826
+ * CI-built image tagged by branch/sha). Itself a template over the provision vars.
827
+ */
828
+ readonly imageTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
829
+ /** Fallback TTL (ms) after which the env is swept + torn down. */
830
+ readonly defaultTtlMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 60000, undefined>]>, undefined>;
831
+ /**
832
+ * How long (seconds) the container deploy adapter waits for each Deployment to roll out
833
+ * before reporting the env still `provisioning` (the backend keeps polling). Only the
834
+ * container-backed render path honors it; absent ⇒ the harness default (180s).
835
+ */
836
+ readonly rolloutTimeoutSeconds: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>]>, undefined>;
837
+ /** Extra labels stamped on the namespace + every applied resource. */
838
+ readonly labels: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
839
+ /** Extra annotations stamped on the namespace. */
840
+ readonly annotations: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
841
+ /** Structured image overrides (the kustomize `images:` shape), templated over provision vars. */
842
+ readonly images: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
843
+ /** The image to match (the `name:` in a kustomization `images:` entry), e.g. `registry/app`. */
844
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
845
+ /** Optional replacement repo, templated; absent ⇒ keep the original repo. */
846
+ readonly newNameTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
847
+ /** Replacement tag, templated (e.g. `{{branch}}` / `{{sha}}`); mutually exclusive with digest. */
848
+ readonly newTagTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
849
+ /** Replacement digest, templated; alternative to a tag. */
850
+ readonly digestTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
851
+ }, undefined>, v.CheckAction<{
852
+ name: string;
853
+ newNameTemplate?: string | undefined;
854
+ newTagTemplate?: string | undefined;
855
+ digestTemplate?: string | undefined;
856
+ }, "an image override must set at least one of newNameTemplate, newTagTemplate, or digestTemplate.">, v.CheckAction<{
857
+ name: string;
858
+ newNameTemplate?: string | undefined;
859
+ newTagTemplate?: string | undefined;
860
+ digestTemplate?: string | undefined;
861
+ }, "newTagTemplate and digestTemplate are mutually exclusive on an image override.">]>, undefined>, undefined>;
862
+ /** Helm releases to install — workspace-shared singletons merged with the service's per-env ones. */
863
+ readonly helmReleases: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
864
+ /** Release name. */
865
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
866
+ /** Chart ref: an OCI ref (`oci://…`) or, with `repo`, a `repo/chart` name. */
867
+ readonly chart: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
868
+ /** Chart repo URL; absent ⇒ `chart` is an OCI ref. */
869
+ readonly repo: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
870
+ /** PINNED chart version, e.g. `1.2.3` / `v1.2.3` (floating tags like `latest`/`^1.0` rejected). */
871
+ readonly version: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "version must be a pinned semver (e.g. 1.2.3), not a floating tag like latest or ^1.0.">]>;
872
+ /** Namespace to install into, templated; absent ⇒ the environment namespace. */
873
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
874
+ /** Inline `--values` overrides. */
875
+ readonly values: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
876
+ /** Templated `--set` overrides. */
877
+ readonly set: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
878
+ /** Dotted `--set` path, e.g. `config.rateLimit.enabled`. */
879
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
880
+ /** The value, templated over the provision vars. */
881
+ readonly valueTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 2000, undefined>]>;
882
+ }, undefined>, undefined>, undefined>;
883
+ /** Secret-bundle-backed values folded in at provision time (`--set <path>=<secret>`). */
884
+ readonly valuesSecretRefs: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
885
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
886
+ readonly secretRef: v.ObjectSchema<{
887
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
888
+ }, undefined>;
889
+ }, undefined>, undefined>, undefined>;
890
+ readonly scope: v.OptionalSchema<v.PicklistSchema<["per-environment", "shared"], undefined>, undefined>;
891
+ }, undefined>, undefined>, undefined>;
892
+ /** Secrets fed in before apply (a `Secret` resource or a `secretGenerator` `.env`). */
893
+ readonly secretInjections: v.OptionalSchema<v.ArraySchema<v.VariantSchema<"mode", [v.ObjectSchema<{
894
+ readonly mode: v.LiteralSchema<"secret", undefined>;
895
+ /** Target Secret name in the namespace. */
896
+ readonly secretName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
897
+ /** Secret `type`; absent ⇒ `Opaque`. */
898
+ readonly secretType: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
899
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
900
+ /** Key inside the rendered Secret / `.env`. */
901
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
902
+ /** Resolve the value from the workspace encrypted bundle by key. */
903
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
904
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
905
+ }, undefined>, undefined>;
906
+ /** OR a non-secret value, templated over the provision vars. */
907
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
908
+ }, undefined>, v.CheckAction<{
909
+ key: string;
910
+ secretRef?: {
911
+ key: string;
912
+ } | undefined;
913
+ valueTemplate?: string | undefined;
914
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
915
+ }, undefined>, v.ObjectSchema<{
916
+ readonly mode: v.LiteralSchema<"generatorEnvFile", undefined>;
917
+ /**
918
+ * Repo-relative path within the overlay tree to write the `KEY=value` env file the
919
+ * overlay's `secretGenerator` reads (e.g. `overlays/<env>/<component>/.env`). The
920
+ * overlay names the Secret.
921
+ */
922
+ readonly envFilePath: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
923
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
924
+ /** Key inside the rendered Secret / `.env`. */
925
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
926
+ /** Resolve the value from the workspace encrypted bundle by key. */
927
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
928
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
929
+ }, undefined>, undefined>;
930
+ /** OR a non-secret value, templated over the provision vars. */
931
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
932
+ }, undefined>, v.CheckAction<{
933
+ key: string;
934
+ secretRef?: {
935
+ key: string;
936
+ } | undefined;
937
+ valueTemplate?: string | undefined;
938
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
939
+ }, undefined>], undefined>, undefined>, undefined>;
940
+ }, undefined>;
941
+ export type EksProvisionConfig = v.InferOutput<typeof eksProvisionConfigSchema>;
756
942
  /** Built-in environment backend kinds the contract knows by name. */
757
- export declare const RESERVED_ENVIRONMENT_BACKEND_KINDS: readonly ['manifest', 'kubernetes'];
943
+ export declare const RESERVED_ENVIRONMENT_BACKEND_KINDS: readonly ['manifest', 'kubernetes', 'eks'];
758
944
  /**
759
945
  * The `kind` slug of a CUSTOM (third-party, programmatically-registered) environment
760
946
  * backend: any lower-kebab slug that isn't a reserved built-in. A custom backend stores
@@ -1083,6 +1269,187 @@ export declare const environmentBackendConfigSchema: v.VariantSchema<"kind", [v.
1083
1269
  }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
1084
1270
  }, undefined>], undefined>, undefined>, undefined>;
1085
1271
  }, undefined>;
1272
+ }, undefined>, v.ObjectSchema<{
1273
+ readonly kind: v.LiteralSchema<"eks", undefined>;
1274
+ readonly eks: v.ObjectSchema<{
1275
+ readonly region: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be an AWS region slug">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
1276
+ readonly clusterName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
1277
+ readonly stsHost: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be a bare host or host:port">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>;
1278
+ /** Human label for the connection (shown in the UI). */
1279
+ readonly label: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
1280
+ /** kube-apiserver root URL, e.g. `https://my-cluster.example:6443`. */
1281
+ readonly apiServerUrl: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>;
1282
+ /** PEM CA bundle to verify the apiserver TLS cert (omit only for a publicly-trusted CA). */
1283
+ readonly caCertPem: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
1284
+ /** Skip apiserver TLS verification — strongly discouraged; kind/dev clusters only. */
1285
+ readonly insecureSkipTlsVerify: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
1286
+ /**
1287
+ * Namespace name template for the per-PR environment, e.g. `cf-env-{{pullNumber}}`.
1288
+ * Rendered with the provision vars then sanitized to an RFC1123 label; absent ⇒ a
1289
+ * default derived from the PR number / block id.
1290
+ */
1291
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 200, undefined>]>, undefined>;
1292
+ /** Where the manifests are read from (co-located in the PR repo, or a separate repo). */
1293
+ readonly manifestSource: v.VariantSchema<"type", [v.ObjectSchema<{
1294
+ readonly type: v.LiteralSchema<"colocated", undefined>;
1295
+ /** File or directory path within the PR repo (read at the PR head branch). */
1296
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
1297
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
1298
+ }, undefined>, v.ObjectSchema<{
1299
+ readonly type: v.LiteralSchema<"separate", undefined>;
1300
+ /** `owner/repo` of the manifests repo. */
1301
+ readonly repo: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be \"owner/repo\"">]>;
1302
+ /** Branch/tag/sha to read at; absent ⇒ that repo's default branch. */
1303
+ readonly ref: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
1304
+ /** File or directory path within the manifests repo. */
1305
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
1306
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
1307
+ }, undefined>], undefined>;
1308
+ /** How the environment URL is derived once applied. */
1309
+ readonly url: v.VariantSchema<"source", [v.ObjectSchema<{
1310
+ readonly source: v.LiteralSchema<"ingressTemplate", undefined>;
1311
+ /** Host template, e.g. `{{branch}}.preview.example.com`; rendered with the provision vars. */
1312
+ readonly hostTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
1313
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
1314
+ }, undefined>, v.ObjectSchema<{
1315
+ readonly source: v.LiteralSchema<"ingressStatus", undefined>;
1316
+ /** Ingress object to read `.status.loadBalancer` from; absent ⇒ the only Ingress applied. */
1317
+ readonly ingressName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
1318
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
1319
+ }, undefined>, v.ObjectSchema<{
1320
+ readonly source: v.LiteralSchema<"serviceStatus", undefined>;
1321
+ /** Service object to read `.status.loadBalancer` (k3s ServiceLB) from. */
1322
+ readonly serviceName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
1323
+ readonly port: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>, v.MaxValueAction<number, 65535, undefined>]>, undefined>;
1324
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
1325
+ }, undefined>, v.ObjectSchema<{
1326
+ readonly source: v.LiteralSchema<"gatewayStatus", undefined>;
1327
+ /** Gateway-API `Gateway` to read `.status.addresses[]` from; absent ⇒ the only one applied. */
1328
+ readonly gatewayName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
1329
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
1330
+ }, undefined>, v.ObjectSchema<{
1331
+ readonly source: v.LiteralSchema<"httpRouteStatus", undefined>;
1332
+ /** `HTTPRoute` whose `parentRefs` resolve to the Gateway address; absent ⇒ the only one applied. */
1333
+ readonly httpRouteName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
1334
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
1335
+ }, undefined>], undefined>;
1336
+ /**
1337
+ * Optional image reference made available to the manifests as `{{image}}` (e.g. a
1338
+ * CI-built image tagged by branch/sha). Itself a template over the provision vars.
1339
+ */
1340
+ readonly imageTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
1341
+ /** Fallback TTL (ms) after which the env is swept + torn down. */
1342
+ readonly defaultTtlMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 60000, undefined>]>, undefined>;
1343
+ /**
1344
+ * How long (seconds) the container deploy adapter waits for each Deployment to roll out
1345
+ * before reporting the env still `provisioning` (the backend keeps polling). Only the
1346
+ * container-backed render path honors it; absent ⇒ the harness default (180s).
1347
+ */
1348
+ readonly rolloutTimeoutSeconds: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>]>, undefined>;
1349
+ /** Extra labels stamped on the namespace + every applied resource. */
1350
+ readonly labels: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
1351
+ /** Extra annotations stamped on the namespace. */
1352
+ readonly annotations: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
1353
+ /** Structured image overrides (the kustomize `images:` shape), templated over provision vars. */
1354
+ readonly images: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1355
+ /** The image to match (the `name:` in a kustomization `images:` entry), e.g. `registry/app`. */
1356
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
1357
+ /** Optional replacement repo, templated; absent ⇒ keep the original repo. */
1358
+ readonly newNameTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
1359
+ /** Replacement tag, templated (e.g. `{{branch}}` / `{{sha}}`); mutually exclusive with digest. */
1360
+ readonly newTagTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
1361
+ /** Replacement digest, templated; alternative to a tag. */
1362
+ readonly digestTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
1363
+ }, undefined>, v.CheckAction<{
1364
+ name: string;
1365
+ newNameTemplate?: string | undefined;
1366
+ newTagTemplate?: string | undefined;
1367
+ digestTemplate?: string | undefined;
1368
+ }, "an image override must set at least one of newNameTemplate, newTagTemplate, or digestTemplate.">, v.CheckAction<{
1369
+ name: string;
1370
+ newNameTemplate?: string | undefined;
1371
+ newTagTemplate?: string | undefined;
1372
+ digestTemplate?: string | undefined;
1373
+ }, "newTagTemplate and digestTemplate are mutually exclusive on an image override.">]>, undefined>, undefined>;
1374
+ /** Helm releases to install — workspace-shared singletons merged with the service's per-env ones. */
1375
+ readonly helmReleases: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1376
+ /** Release name. */
1377
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
1378
+ /** Chart ref: an OCI ref (`oci://…`) or, with `repo`, a `repo/chart` name. */
1379
+ readonly chart: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
1380
+ /** Chart repo URL; absent ⇒ `chart` is an OCI ref. */
1381
+ readonly repo: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
1382
+ /** PINNED chart version, e.g. `1.2.3` / `v1.2.3` (floating tags like `latest`/`^1.0` rejected). */
1383
+ readonly version: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "version must be a pinned semver (e.g. 1.2.3), not a floating tag like latest or ^1.0.">]>;
1384
+ /** Namespace to install into, templated; absent ⇒ the environment namespace. */
1385
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
1386
+ /** Inline `--values` overrides. */
1387
+ readonly values: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
1388
+ /** Templated `--set` overrides. */
1389
+ readonly set: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1390
+ /** Dotted `--set` path, e.g. `config.rateLimit.enabled`. */
1391
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
1392
+ /** The value, templated over the provision vars. */
1393
+ readonly valueTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 2000, undefined>]>;
1394
+ }, undefined>, undefined>, undefined>;
1395
+ /** Secret-bundle-backed values folded in at provision time (`--set <path>=<secret>`). */
1396
+ readonly valuesSecretRefs: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
1397
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
1398
+ readonly secretRef: v.ObjectSchema<{
1399
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
1400
+ }, undefined>;
1401
+ }, undefined>, undefined>, undefined>;
1402
+ readonly scope: v.OptionalSchema<v.PicklistSchema<["per-environment", "shared"], undefined>, undefined>;
1403
+ }, undefined>, undefined>, undefined>;
1404
+ /** Secrets fed in before apply (a `Secret` resource or a `secretGenerator` `.env`). */
1405
+ readonly secretInjections: v.OptionalSchema<v.ArraySchema<v.VariantSchema<"mode", [v.ObjectSchema<{
1406
+ readonly mode: v.LiteralSchema<"secret", undefined>;
1407
+ /** Target Secret name in the namespace. */
1408
+ readonly secretName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
1409
+ /** Secret `type`; absent ⇒ `Opaque`. */
1410
+ readonly secretType: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
1411
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1412
+ /** Key inside the rendered Secret / `.env`. */
1413
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
1414
+ /** Resolve the value from the workspace encrypted bundle by key. */
1415
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
1416
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
1417
+ }, undefined>, undefined>;
1418
+ /** OR a non-secret value, templated over the provision vars. */
1419
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
1420
+ }, undefined>, v.CheckAction<{
1421
+ key: string;
1422
+ secretRef?: {
1423
+ key: string;
1424
+ } | undefined;
1425
+ valueTemplate?: string | undefined;
1426
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
1427
+ }, undefined>, v.ObjectSchema<{
1428
+ readonly mode: v.LiteralSchema<"generatorEnvFile", undefined>;
1429
+ /**
1430
+ * Repo-relative path within the overlay tree to write the `KEY=value` env file the
1431
+ * overlay's `secretGenerator` reads (e.g. `overlays/<env>/<component>/.env`). The
1432
+ * overlay names the Secret.
1433
+ */
1434
+ readonly envFilePath: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
1435
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
1436
+ /** Key inside the rendered Secret / `.env`. */
1437
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
1438
+ /** Resolve the value from the workspace encrypted bundle by key. */
1439
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
1440
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
1441
+ }, undefined>, undefined>;
1442
+ /** OR a non-secret value, templated over the provision vars. */
1443
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
1444
+ }, undefined>, v.CheckAction<{
1445
+ key: string;
1446
+ secretRef?: {
1447
+ key: string;
1448
+ } | undefined;
1449
+ valueTemplate?: string | undefined;
1450
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
1451
+ }, undefined>], undefined>, undefined>, undefined>;
1452
+ }, undefined>;
1086
1453
  }, undefined>, v.ObjectSchema<{
1087
1454
  readonly kind: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>, v.RegexAction<string, "must be a lower-kebab slug">, v.CheckAction<string, "reserved backend kind">]>;
1088
1455
  readonly manifest: v.ObjectSchema<{
@@ -4513,47 +4880,228 @@ export declare const environmentConnectionSchema: v.ObjectSchema<{
4513
4880
  readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
4514
4881
  readonly value: v.StringSchema<undefined>;
4515
4882
  }, undefined>, undefined>, undefined>;
4516
- readonly bodyTemplate: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4517
- /** Per-call timeout (ms). Bounded; defaults applied by the adapter. */
4518
- readonly timeoutMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 1, undefined>, v.MaxValueAction<number, 60000, undefined>]>, undefined>;
4519
- }, undefined>, undefined>;
4520
- readonly response: v.ObjectSchema<{
4521
- readonly urlPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4522
- readonly statusPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4523
- readonly statusMap: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
4524
- readonly from: v.StringSchema<undefined>;
4525
- readonly to: v.PicklistSchema<["provisioning", "ready", "failed", "expired", "tearing_down", "torn_down"], undefined>;
4883
+ readonly bodyTemplate: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4884
+ /** Per-call timeout (ms). Bounded; defaults applied by the adapter. */
4885
+ readonly timeoutMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 1, undefined>, v.MaxValueAction<number, 60000, undefined>]>, undefined>;
4886
+ }, undefined>, undefined>;
4887
+ readonly response: v.ObjectSchema<{
4888
+ readonly urlPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4889
+ readonly statusPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4890
+ readonly statusMap: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
4891
+ readonly from: v.StringSchema<undefined>;
4892
+ readonly to: v.PicklistSchema<["provisioning", "ready", "failed", "expired", "tearing_down", "torn_down"], undefined>;
4893
+ }, undefined>, undefined>, undefined>;
4894
+ readonly expiresAtPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4895
+ readonly externalIdPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4896
+ readonly access: v.OptionalSchema<v.ObjectSchema<{
4897
+ readonly scheme: v.PicklistSchema<["none", "bearer", "basic", "custom_header"], undefined>;
4898
+ readonly tokenPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4899
+ readonly usernamePath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4900
+ readonly passwordPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4901
+ readonly headerName: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4902
+ readonly headerValuePath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4903
+ }, undefined>, undefined>;
4904
+ }, undefined>;
4905
+ /** Fallback TTL (ms) when the response carries no explicit expiry. */
4906
+ readonly defaultTtlMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 60000, undefined>]>, undefined>;
4907
+ /**
4908
+ * Opaque, provider-specific configuration for a CUSTOM backend (e.g. a Kargo project,
4909
+ * link-selection key, status map). The generic HttpEnvironmentProvider ignores it
4910
+ * entirely; a custom backend — registered by reference into the app-owned
4911
+ * `EnvironmentBackendRegistry` (see `backend/docs/native-environment-adapter.md`) — reads
4912
+ * + validates it off the per-call
4913
+ * `manifest`. This is the per-WORKSPACE config carrier: a custom backend rides the generic
4914
+ * manifest member of `environmentBackendConfigSchema`, so its bespoke settings live here and
4915
+ * its credentials in the secret bundle. NOT covered by the manifest URL/SSRF checks (which
4916
+ * only guard `baseUrl`/`tokenUrl`); a backend that puts a URL here must guard it itself
4917
+ * (reuse the exported `UrlSafetyPolicy`).
4918
+ */
4919
+ readonly providerConfig: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
4920
+ }, undefined>;
4921
+ }, undefined>, v.ObjectSchema<{
4922
+ readonly kind: v.LiteralSchema<"kubernetes", undefined>;
4923
+ readonly kubernetes: v.ObjectSchema<{
4924
+ /** Human label for the connection (shown in the UI). */
4925
+ readonly label: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
4926
+ /** kube-apiserver root URL, e.g. `https://my-cluster.example:6443`. */
4927
+ readonly apiServerUrl: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>;
4928
+ /** PEM CA bundle to verify the apiserver TLS cert (omit only for a publicly-trusted CA). */
4929
+ readonly caCertPem: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4930
+ /** Skip apiserver TLS verification — strongly discouraged; kind/dev clusters only. */
4931
+ readonly insecureSkipTlsVerify: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
4932
+ /**
4933
+ * Namespace name template for the per-PR environment, e.g. `cf-env-{{pullNumber}}`.
4934
+ * Rendered with the provision vars then sanitized to an RFC1123 label; absent ⇒ a
4935
+ * default derived from the PR number / block id.
4936
+ */
4937
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 200, undefined>]>, undefined>;
4938
+ /** Where the manifests are read from (co-located in the PR repo, or a separate repo). */
4939
+ readonly manifestSource: v.VariantSchema<"type", [v.ObjectSchema<{
4940
+ readonly type: v.LiteralSchema<"colocated", undefined>;
4941
+ /** File or directory path within the PR repo (read at the PR head branch). */
4942
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
4943
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
4944
+ }, undefined>, v.ObjectSchema<{
4945
+ readonly type: v.LiteralSchema<"separate", undefined>;
4946
+ /** `owner/repo` of the manifests repo. */
4947
+ readonly repo: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be \"owner/repo\"">]>;
4948
+ /** Branch/tag/sha to read at; absent ⇒ that repo's default branch. */
4949
+ readonly ref: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
4950
+ /** File or directory path within the manifests repo. */
4951
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
4952
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
4953
+ }, undefined>], undefined>;
4954
+ /** How the environment URL is derived once applied. */
4955
+ readonly url: v.VariantSchema<"source", [v.ObjectSchema<{
4956
+ readonly source: v.LiteralSchema<"ingressTemplate", undefined>;
4957
+ /** Host template, e.g. `{{branch}}.preview.example.com`; rendered with the provision vars. */
4958
+ readonly hostTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
4959
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
4960
+ }, undefined>, v.ObjectSchema<{
4961
+ readonly source: v.LiteralSchema<"ingressStatus", undefined>;
4962
+ /** Ingress object to read `.status.loadBalancer` from; absent ⇒ the only Ingress applied. */
4963
+ readonly ingressName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
4964
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
4965
+ }, undefined>, v.ObjectSchema<{
4966
+ readonly source: v.LiteralSchema<"serviceStatus", undefined>;
4967
+ /** Service object to read `.status.loadBalancer` (k3s ServiceLB) from. */
4968
+ readonly serviceName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
4969
+ readonly port: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>, v.MaxValueAction<number, 65535, undefined>]>, undefined>;
4970
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
4971
+ }, undefined>, v.ObjectSchema<{
4972
+ readonly source: v.LiteralSchema<"gatewayStatus", undefined>;
4973
+ /** Gateway-API `Gateway` to read `.status.addresses[]` from; absent ⇒ the only one applied. */
4974
+ readonly gatewayName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
4975
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
4976
+ }, undefined>, v.ObjectSchema<{
4977
+ readonly source: v.LiteralSchema<"httpRouteStatus", undefined>;
4978
+ /** `HTTPRoute` whose `parentRefs` resolve to the Gateway address; absent ⇒ the only one applied. */
4979
+ readonly httpRouteName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
4980
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
4981
+ }, undefined>], undefined>;
4982
+ /**
4983
+ * Optional image reference made available to the manifests as `{{image}}` (e.g. a
4984
+ * CI-built image tagged by branch/sha). Itself a template over the provision vars.
4985
+ */
4986
+ readonly imageTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
4987
+ /** Fallback TTL (ms) after which the env is swept + torn down. */
4988
+ readonly defaultTtlMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 60000, undefined>]>, undefined>;
4989
+ /**
4990
+ * How long (seconds) the container deploy adapter waits for each Deployment to roll out
4991
+ * before reporting the env still `provisioning` (the backend keeps polling). Only the
4992
+ * container-backed render path honors it; absent ⇒ the harness default (180s).
4993
+ */
4994
+ readonly rolloutTimeoutSeconds: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>]>, undefined>;
4995
+ /** Extra labels stamped on the namespace + every applied resource. */
4996
+ readonly labels: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
4997
+ /** Extra annotations stamped on the namespace. */
4998
+ readonly annotations: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
4999
+ /** Structured image overrides (the kustomize `images:` shape), templated over provision vars. */
5000
+ readonly images: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
5001
+ /** The image to match (the `name:` in a kustomization `images:` entry), e.g. `registry/app`. */
5002
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5003
+ /** Optional replacement repo, templated; absent ⇒ keep the original repo. */
5004
+ readonly newNameTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
5005
+ /** Replacement tag, templated (e.g. `{{branch}}` / `{{sha}}`); mutually exclusive with digest. */
5006
+ readonly newTagTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
5007
+ /** Replacement digest, templated; alternative to a tag. */
5008
+ readonly digestTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
5009
+ }, undefined>, v.CheckAction<{
5010
+ name: string;
5011
+ newNameTemplate?: string | undefined;
5012
+ newTagTemplate?: string | undefined;
5013
+ digestTemplate?: string | undefined;
5014
+ }, "an image override must set at least one of newNameTemplate, newTagTemplate, or digestTemplate.">, v.CheckAction<{
5015
+ name: string;
5016
+ newNameTemplate?: string | undefined;
5017
+ newTagTemplate?: string | undefined;
5018
+ digestTemplate?: string | undefined;
5019
+ }, "newTagTemplate and digestTemplate are mutually exclusive on an image override.">]>, undefined>, undefined>;
5020
+ /** Helm releases to install — workspace-shared singletons merged with the service's per-env ones. */
5021
+ readonly helmReleases: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
5022
+ /** Release name. */
5023
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5024
+ /** Chart ref: an OCI ref (`oci://…`) or, with `repo`, a `repo/chart` name. */
5025
+ readonly chart: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5026
+ /** Chart repo URL; absent ⇒ `chart` is an OCI ref. */
5027
+ readonly repo: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
5028
+ /** PINNED chart version, e.g. `1.2.3` / `v1.2.3` (floating tags like `latest`/`^1.0` rejected). */
5029
+ readonly version: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "version must be a pinned semver (e.g. 1.2.3), not a floating tag like latest or ^1.0.">]>;
5030
+ /** Namespace to install into, templated; absent ⇒ the environment namespace. */
5031
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
5032
+ /** Inline `--values` overrides. */
5033
+ readonly values: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
5034
+ /** Templated `--set` overrides. */
5035
+ readonly set: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
5036
+ /** Dotted `--set` path, e.g. `config.rateLimit.enabled`. */
5037
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5038
+ /** The value, templated over the provision vars. */
5039
+ readonly valueTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 2000, undefined>]>;
5040
+ }, undefined>, undefined>, undefined>;
5041
+ /** Secret-bundle-backed values folded in at provision time (`--set <path>=<secret>`). */
5042
+ readonly valuesSecretRefs: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
5043
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5044
+ readonly secretRef: v.ObjectSchema<{
5045
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
5046
+ }, undefined>;
4526
5047
  }, undefined>, undefined>, undefined>;
4527
- readonly expiresAtPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4528
- readonly externalIdPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4529
- readonly access: v.OptionalSchema<v.ObjectSchema<{
4530
- readonly scheme: v.PicklistSchema<["none", "bearer", "basic", "custom_header"], undefined>;
4531
- readonly tokenPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4532
- readonly usernamePath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4533
- readonly passwordPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4534
- readonly headerName: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4535
- readonly headerValuePath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4536
- }, undefined>, undefined>;
4537
- }, undefined>;
4538
- /** Fallback TTL (ms) when the response carries no explicit expiry. */
4539
- readonly defaultTtlMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 60000, undefined>]>, undefined>;
4540
- /**
4541
- * Opaque, provider-specific configuration for a CUSTOM backend (e.g. a Kargo project,
4542
- * link-selection key, status map). The generic HttpEnvironmentProvider ignores it
4543
- * entirely; a custom backend registered by reference into the app-owned
4544
- * `EnvironmentBackendRegistry` (see `backend/docs/native-environment-adapter.md`) reads
4545
- * + validates it off the per-call
4546
- * `manifest`. This is the per-WORKSPACE config carrier: a custom backend rides the generic
4547
- * manifest member of `environmentBackendConfigSchema`, so its bespoke settings live here and
4548
- * its credentials in the secret bundle. NOT covered by the manifest URL/SSRF checks (which
4549
- * only guard `baseUrl`/`tokenUrl`); a backend that puts a URL here must guard it itself
4550
- * (reuse the exported `UrlSafetyPolicy`).
4551
- */
4552
- readonly providerConfig: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
5048
+ readonly scope: v.OptionalSchema<v.PicklistSchema<["per-environment", "shared"], undefined>, undefined>;
5049
+ }, undefined>, undefined>, undefined>;
5050
+ /** Secrets fed in before apply (a `Secret` resource or a `secretGenerator` `.env`). */
5051
+ readonly secretInjections: v.OptionalSchema<v.ArraySchema<v.VariantSchema<"mode", [v.ObjectSchema<{
5052
+ readonly mode: v.LiteralSchema<"secret", undefined>;
5053
+ /** Target Secret name in the namespace. */
5054
+ readonly secretName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5055
+ /** Secret `type`; absent ⇒ `Opaque`. */
5056
+ readonly secretType: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
5057
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
5058
+ /** Key inside the rendered Secret / `.env`. */
5059
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
5060
+ /** Resolve the value from the workspace encrypted bundle by key. */
5061
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
5062
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
5063
+ }, undefined>, undefined>;
5064
+ /** OR a non-secret value, templated over the provision vars. */
5065
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
5066
+ }, undefined>, v.CheckAction<{
5067
+ key: string;
5068
+ secretRef?: {
5069
+ key: string;
5070
+ } | undefined;
5071
+ valueTemplate?: string | undefined;
5072
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
5073
+ }, undefined>, v.ObjectSchema<{
5074
+ readonly mode: v.LiteralSchema<"generatorEnvFile", undefined>;
5075
+ /**
5076
+ * Repo-relative path within the overlay tree to write the `KEY=value` env file the
5077
+ * overlay's `secretGenerator` reads (e.g. `overlays/<env>/<component>/.env`). The
5078
+ * overlay names the Secret.
5079
+ */
5080
+ readonly envFilePath: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
5081
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
5082
+ /** Key inside the rendered Secret / `.env`. */
5083
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
5084
+ /** Resolve the value from the workspace encrypted bundle by key. */
5085
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
5086
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
5087
+ }, undefined>, undefined>;
5088
+ /** OR a non-secret value, templated over the provision vars. */
5089
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
5090
+ }, undefined>, v.CheckAction<{
5091
+ key: string;
5092
+ secretRef?: {
5093
+ key: string;
5094
+ } | undefined;
5095
+ valueTemplate?: string | undefined;
5096
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
5097
+ }, undefined>], undefined>, undefined>, undefined>;
4553
5098
  }, undefined>;
4554
5099
  }, undefined>, v.ObjectSchema<{
4555
- readonly kind: v.LiteralSchema<"kubernetes", undefined>;
4556
- readonly kubernetes: v.ObjectSchema<{
5100
+ readonly kind: v.LiteralSchema<"eks", undefined>;
5101
+ readonly eks: v.ObjectSchema<{
5102
+ readonly region: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be an AWS region slug">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
5103
+ readonly clusterName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
5104
+ readonly stsHost: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be a bare host or host:port">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>;
4557
5105
  /** Human label for the connection (shown in the UI). */
4558
5106
  readonly label: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
4559
5107
  /** kube-apiserver root URL, e.g. `https://my-cluster.example:6443`. */
@@ -4976,36 +5524,217 @@ export declare const registerEnvironmentProviderSchema: v.ObjectSchema<{
4976
5524
  readonly from: v.StringSchema<undefined>;
4977
5525
  readonly to: v.PicklistSchema<["provisioning", "ready", "failed", "expired", "tearing_down", "torn_down"], undefined>;
4978
5526
  }, undefined>, undefined>, undefined>;
4979
- readonly expiresAtPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4980
- readonly externalIdPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4981
- readonly access: v.OptionalSchema<v.ObjectSchema<{
4982
- readonly scheme: v.PicklistSchema<["none", "bearer", "basic", "custom_header"], undefined>;
4983
- readonly tokenPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4984
- readonly usernamePath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4985
- readonly passwordPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4986
- readonly headerName: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4987
- readonly headerValuePath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
4988
- }, undefined>, undefined>;
4989
- }, undefined>;
4990
- /** Fallback TTL (ms) when the response carries no explicit expiry. */
4991
- readonly defaultTtlMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 60000, undefined>]>, undefined>;
4992
- /**
4993
- * Opaque, provider-specific configuration for a CUSTOM backend (e.g. a Kargo project,
4994
- * link-selection key, status map). The generic HttpEnvironmentProvider ignores it
4995
- * entirely; a custom backend — registered by reference into the app-owned
4996
- * `EnvironmentBackendRegistry` (see `backend/docs/native-environment-adapter.md`) — reads
4997
- * + validates it off the per-call
4998
- * `manifest`. This is the per-WORKSPACE config carrier: a custom backend rides the generic
4999
- * manifest member of `environmentBackendConfigSchema`, so its bespoke settings live here and
5000
- * its credentials in the secret bundle. NOT covered by the manifest URL/SSRF checks (which
5001
- * only guard `baseUrl`/`tokenUrl`); a backend that puts a URL here must guard it itself
5002
- * (reuse the exported `UrlSafetyPolicy`).
5003
- */
5004
- readonly providerConfig: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
5527
+ readonly expiresAtPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
5528
+ readonly externalIdPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
5529
+ readonly access: v.OptionalSchema<v.ObjectSchema<{
5530
+ readonly scheme: v.PicklistSchema<["none", "bearer", "basic", "custom_header"], undefined>;
5531
+ readonly tokenPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
5532
+ readonly usernamePath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
5533
+ readonly passwordPath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
5534
+ readonly headerName: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
5535
+ readonly headerValuePath: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
5536
+ }, undefined>, undefined>;
5537
+ }, undefined>;
5538
+ /** Fallback TTL (ms) when the response carries no explicit expiry. */
5539
+ readonly defaultTtlMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 60000, undefined>]>, undefined>;
5540
+ /**
5541
+ * Opaque, provider-specific configuration for a CUSTOM backend (e.g. a Kargo project,
5542
+ * link-selection key, status map). The generic HttpEnvironmentProvider ignores it
5543
+ * entirely; a custom backend — registered by reference into the app-owned
5544
+ * `EnvironmentBackendRegistry` (see `backend/docs/native-environment-adapter.md`) — reads
5545
+ * + validates it off the per-call
5546
+ * `manifest`. This is the per-WORKSPACE config carrier: a custom backend rides the generic
5547
+ * manifest member of `environmentBackendConfigSchema`, so its bespoke settings live here and
5548
+ * its credentials in the secret bundle. NOT covered by the manifest URL/SSRF checks (which
5549
+ * only guard `baseUrl`/`tokenUrl`); a backend that puts a URL here must guard it itself
5550
+ * (reuse the exported `UrlSafetyPolicy`).
5551
+ */
5552
+ readonly providerConfig: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
5553
+ }, undefined>;
5554
+ }, undefined>, v.ObjectSchema<{
5555
+ readonly kind: v.LiteralSchema<"kubernetes", undefined>;
5556
+ readonly kubernetes: v.ObjectSchema<{
5557
+ /** Human label for the connection (shown in the UI). */
5558
+ readonly label: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
5559
+ /** kube-apiserver root URL, e.g. `https://my-cluster.example:6443`. */
5560
+ readonly apiServerUrl: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>;
5561
+ /** PEM CA bundle to verify the apiserver TLS cert (omit only for a publicly-trusted CA). */
5562
+ readonly caCertPem: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
5563
+ /** Skip apiserver TLS verification — strongly discouraged; kind/dev clusters only. */
5564
+ readonly insecureSkipTlsVerify: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
5565
+ /**
5566
+ * Namespace name template for the per-PR environment, e.g. `cf-env-{{pullNumber}}`.
5567
+ * Rendered with the provision vars then sanitized to an RFC1123 label; absent ⇒ a
5568
+ * default derived from the PR number / block id.
5569
+ */
5570
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 200, undefined>]>, undefined>;
5571
+ /** Where the manifests are read from (co-located in the PR repo, or a separate repo). */
5572
+ readonly manifestSource: v.VariantSchema<"type", [v.ObjectSchema<{
5573
+ readonly type: v.LiteralSchema<"colocated", undefined>;
5574
+ /** File or directory path within the PR repo (read at the PR head branch). */
5575
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
5576
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
5577
+ }, undefined>, v.ObjectSchema<{
5578
+ readonly type: v.LiteralSchema<"separate", undefined>;
5579
+ /** `owner/repo` of the manifests repo. */
5580
+ readonly repo: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be \"owner/repo\"">]>;
5581
+ /** Branch/tag/sha to read at; absent ⇒ that repo's default branch. */
5582
+ readonly ref: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
5583
+ /** File or directory path within the manifests repo. */
5584
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
5585
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
5586
+ }, undefined>], undefined>;
5587
+ /** How the environment URL is derived once applied. */
5588
+ readonly url: v.VariantSchema<"source", [v.ObjectSchema<{
5589
+ readonly source: v.LiteralSchema<"ingressTemplate", undefined>;
5590
+ /** Host template, e.g. `{{branch}}.preview.example.com`; rendered with the provision vars. */
5591
+ readonly hostTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
5592
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
5593
+ }, undefined>, v.ObjectSchema<{
5594
+ readonly source: v.LiteralSchema<"ingressStatus", undefined>;
5595
+ /** Ingress object to read `.status.loadBalancer` from; absent ⇒ the only Ingress applied. */
5596
+ readonly ingressName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
5597
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
5598
+ }, undefined>, v.ObjectSchema<{
5599
+ readonly source: v.LiteralSchema<"serviceStatus", undefined>;
5600
+ /** Service object to read `.status.loadBalancer` (k3s ServiceLB) from. */
5601
+ readonly serviceName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
5602
+ readonly port: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>, v.MaxValueAction<number, 65535, undefined>]>, undefined>;
5603
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
5604
+ }, undefined>, v.ObjectSchema<{
5605
+ readonly source: v.LiteralSchema<"gatewayStatus", undefined>;
5606
+ /** Gateway-API `Gateway` to read `.status.addresses[]` from; absent ⇒ the only one applied. */
5607
+ readonly gatewayName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
5608
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
5609
+ }, undefined>, v.ObjectSchema<{
5610
+ readonly source: v.LiteralSchema<"httpRouteStatus", undefined>;
5611
+ /** `HTTPRoute` whose `parentRefs` resolve to the Gateway address; absent ⇒ the only one applied. */
5612
+ readonly httpRouteName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
5613
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
5614
+ }, undefined>], undefined>;
5615
+ /**
5616
+ * Optional image reference made available to the manifests as `{{image}}` (e.g. a
5617
+ * CI-built image tagged by branch/sha). Itself a template over the provision vars.
5618
+ */
5619
+ readonly imageTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
5620
+ /** Fallback TTL (ms) after which the env is swept + torn down. */
5621
+ readonly defaultTtlMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 60000, undefined>]>, undefined>;
5622
+ /**
5623
+ * How long (seconds) the container deploy adapter waits for each Deployment to roll out
5624
+ * before reporting the env still `provisioning` (the backend keeps polling). Only the
5625
+ * container-backed render path honors it; absent ⇒ the harness default (180s).
5626
+ */
5627
+ readonly rolloutTimeoutSeconds: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>]>, undefined>;
5628
+ /** Extra labels stamped on the namespace + every applied resource. */
5629
+ readonly labels: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
5630
+ /** Extra annotations stamped on the namespace. */
5631
+ readonly annotations: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
5632
+ /** Structured image overrides (the kustomize `images:` shape), templated over provision vars. */
5633
+ readonly images: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
5634
+ /** The image to match (the `name:` in a kustomization `images:` entry), e.g. `registry/app`. */
5635
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5636
+ /** Optional replacement repo, templated; absent ⇒ keep the original repo. */
5637
+ readonly newNameTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
5638
+ /** Replacement tag, templated (e.g. `{{branch}}` / `{{sha}}`); mutually exclusive with digest. */
5639
+ readonly newTagTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
5640
+ /** Replacement digest, templated; alternative to a tag. */
5641
+ readonly digestTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
5642
+ }, undefined>, v.CheckAction<{
5643
+ name: string;
5644
+ newNameTemplate?: string | undefined;
5645
+ newTagTemplate?: string | undefined;
5646
+ digestTemplate?: string | undefined;
5647
+ }, "an image override must set at least one of newNameTemplate, newTagTemplate, or digestTemplate.">, v.CheckAction<{
5648
+ name: string;
5649
+ newNameTemplate?: string | undefined;
5650
+ newTagTemplate?: string | undefined;
5651
+ digestTemplate?: string | undefined;
5652
+ }, "newTagTemplate and digestTemplate are mutually exclusive on an image override.">]>, undefined>, undefined>;
5653
+ /** Helm releases to install — workspace-shared singletons merged with the service's per-env ones. */
5654
+ readonly helmReleases: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
5655
+ /** Release name. */
5656
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5657
+ /** Chart ref: an OCI ref (`oci://…`) or, with `repo`, a `repo/chart` name. */
5658
+ readonly chart: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5659
+ /** Chart repo URL; absent ⇒ `chart` is an OCI ref. */
5660
+ readonly repo: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
5661
+ /** PINNED chart version, e.g. `1.2.3` / `v1.2.3` (floating tags like `latest`/`^1.0` rejected). */
5662
+ readonly version: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "version must be a pinned semver (e.g. 1.2.3), not a floating tag like latest or ^1.0.">]>;
5663
+ /** Namespace to install into, templated; absent ⇒ the environment namespace. */
5664
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
5665
+ /** Inline `--values` overrides. */
5666
+ readonly values: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
5667
+ /** Templated `--set` overrides. */
5668
+ readonly set: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
5669
+ /** Dotted `--set` path, e.g. `config.rateLimit.enabled`. */
5670
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5671
+ /** The value, templated over the provision vars. */
5672
+ readonly valueTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 2000, undefined>]>;
5673
+ }, undefined>, undefined>, undefined>;
5674
+ /** Secret-bundle-backed values folded in at provision time (`--set <path>=<secret>`). */
5675
+ readonly valuesSecretRefs: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
5676
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5677
+ readonly secretRef: v.ObjectSchema<{
5678
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
5679
+ }, undefined>;
5680
+ }, undefined>, undefined>, undefined>;
5681
+ readonly scope: v.OptionalSchema<v.PicklistSchema<["per-environment", "shared"], undefined>, undefined>;
5682
+ }, undefined>, undefined>, undefined>;
5683
+ /** Secrets fed in before apply (a `Secret` resource or a `secretGenerator` `.env`). */
5684
+ readonly secretInjections: v.OptionalSchema<v.ArraySchema<v.VariantSchema<"mode", [v.ObjectSchema<{
5685
+ readonly mode: v.LiteralSchema<"secret", undefined>;
5686
+ /** Target Secret name in the namespace. */
5687
+ readonly secretName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
5688
+ /** Secret `type`; absent ⇒ `Opaque`. */
5689
+ readonly secretType: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
5690
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
5691
+ /** Key inside the rendered Secret / `.env`. */
5692
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
5693
+ /** Resolve the value from the workspace encrypted bundle by key. */
5694
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
5695
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
5696
+ }, undefined>, undefined>;
5697
+ /** OR a non-secret value, templated over the provision vars. */
5698
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
5699
+ }, undefined>, v.CheckAction<{
5700
+ key: string;
5701
+ secretRef?: {
5702
+ key: string;
5703
+ } | undefined;
5704
+ valueTemplate?: string | undefined;
5705
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
5706
+ }, undefined>, v.ObjectSchema<{
5707
+ readonly mode: v.LiteralSchema<"generatorEnvFile", undefined>;
5708
+ /**
5709
+ * Repo-relative path within the overlay tree to write the `KEY=value` env file the
5710
+ * overlay's `secretGenerator` reads (e.g. `overlays/<env>/<component>/.env`). The
5711
+ * overlay names the Secret.
5712
+ */
5713
+ readonly envFilePath: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
5714
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
5715
+ /** Key inside the rendered Secret / `.env`. */
5716
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
5717
+ /** Resolve the value from the workspace encrypted bundle by key. */
5718
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
5719
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
5720
+ }, undefined>, undefined>;
5721
+ /** OR a non-secret value, templated over the provision vars. */
5722
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
5723
+ }, undefined>, v.CheckAction<{
5724
+ key: string;
5725
+ secretRef?: {
5726
+ key: string;
5727
+ } | undefined;
5728
+ valueTemplate?: string | undefined;
5729
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
5730
+ }, undefined>], undefined>, undefined>, undefined>;
5005
5731
  }, undefined>;
5006
5732
  }, undefined>, v.ObjectSchema<{
5007
- readonly kind: v.LiteralSchema<"kubernetes", undefined>;
5008
- readonly kubernetes: v.ObjectSchema<{
5733
+ readonly kind: v.LiteralSchema<"eks", undefined>;
5734
+ readonly eks: v.ObjectSchema<{
5735
+ readonly region: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be an AWS region slug">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
5736
+ readonly clusterName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
5737
+ readonly stsHost: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be a bare host or host:port">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>;
5009
5738
  /** Human label for the connection (shown in the UI). */
5010
5739
  readonly label: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
5011
5740
  /** kube-apiserver root URL, e.g. `https://my-cluster.example:6443`. */
@@ -5635,6 +6364,187 @@ export declare const testEnvironmentConnectionSchema: v.ObjectSchema<{
5635
6364
  }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
5636
6365
  }, undefined>], undefined>, undefined>, undefined>;
5637
6366
  }, undefined>;
6367
+ }, undefined>, v.ObjectSchema<{
6368
+ readonly kind: v.LiteralSchema<"eks", undefined>;
6369
+ readonly eks: v.ObjectSchema<{
6370
+ readonly region: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be an AWS region slug">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
6371
+ readonly clusterName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
6372
+ readonly stsHost: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be a bare host or host:port">, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 255, undefined>]>, undefined>;
6373
+ /** Human label for the connection (shown in the UI). */
6374
+ readonly label: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 120, undefined>]>;
6375
+ /** kube-apiserver root URL, e.g. `https://my-cluster.example:6443`. */
6376
+ readonly apiServerUrl: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>;
6377
+ /** PEM CA bundle to verify the apiserver TLS cert (omit only for a publicly-trusted CA). */
6378
+ readonly caCertPem: v.OptionalSchema<v.StringSchema<undefined>, undefined>;
6379
+ /** Skip apiserver TLS verification — strongly discouraged; kind/dev clusters only. */
6380
+ readonly insecureSkipTlsVerify: v.OptionalSchema<v.BooleanSchema<undefined>, undefined>;
6381
+ /**
6382
+ * Namespace name template for the per-PR environment, e.g. `cf-env-{{pullNumber}}`.
6383
+ * Rendered with the provision vars then sanitized to an RFC1123 label; absent ⇒ a
6384
+ * default derived from the PR number / block id.
6385
+ */
6386
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 200, undefined>]>, undefined>;
6387
+ /** Where the manifests are read from (co-located in the PR repo, or a separate repo). */
6388
+ readonly manifestSource: v.VariantSchema<"type", [v.ObjectSchema<{
6389
+ readonly type: v.LiteralSchema<"colocated", undefined>;
6390
+ /** File or directory path within the PR repo (read at the PR head branch). */
6391
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
6392
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
6393
+ }, undefined>, v.ObjectSchema<{
6394
+ readonly type: v.LiteralSchema<"separate", undefined>;
6395
+ /** `owner/repo` of the manifests repo. */
6396
+ readonly repo: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "must be \"owner/repo\"">]>;
6397
+ /** Branch/tag/sha to read at; absent ⇒ that repo's default branch. */
6398
+ readonly ref: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
6399
+ /** File or directory path within the manifests repo. */
6400
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
6401
+ readonly renderer: v.OptionalSchema<v.PicklistSchema<["raw", "kustomize"], undefined>, undefined>;
6402
+ }, undefined>], undefined>;
6403
+ /** How the environment URL is derived once applied. */
6404
+ readonly url: v.VariantSchema<"source", [v.ObjectSchema<{
6405
+ readonly source: v.LiteralSchema<"ingressTemplate", undefined>;
6406
+ /** Host template, e.g. `{{branch}}.preview.example.com`; rendered with the provision vars. */
6407
+ readonly hostTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
6408
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
6409
+ }, undefined>, v.ObjectSchema<{
6410
+ readonly source: v.LiteralSchema<"ingressStatus", undefined>;
6411
+ /** Ingress object to read `.status.loadBalancer` from; absent ⇒ the only Ingress applied. */
6412
+ readonly ingressName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
6413
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
6414
+ }, undefined>, v.ObjectSchema<{
6415
+ readonly source: v.LiteralSchema<"serviceStatus", undefined>;
6416
+ /** Service object to read `.status.loadBalancer` (k3s ServiceLB) from. */
6417
+ readonly serviceName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>;
6418
+ readonly port: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>, v.MaxValueAction<number, 65535, undefined>]>, undefined>;
6419
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
6420
+ }, undefined>, v.ObjectSchema<{
6421
+ readonly source: v.LiteralSchema<"gatewayStatus", undefined>;
6422
+ /** Gateway-API `Gateway` to read `.status.addresses[]` from; absent ⇒ the only one applied. */
6423
+ readonly gatewayName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
6424
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
6425
+ }, undefined>, v.ObjectSchema<{
6426
+ readonly source: v.LiteralSchema<"httpRouteStatus", undefined>;
6427
+ /** `HTTPRoute` whose `parentRefs` resolve to the Gateway address; absent ⇒ the only one applied. */
6428
+ readonly httpRouteName: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>]>, undefined>;
6429
+ readonly scheme: v.OptionalSchema<v.PicklistSchema<["http", "https"], undefined>, undefined>;
6430
+ }, undefined>], undefined>;
6431
+ /**
6432
+ * Optional image reference made available to the manifests as `{{image}}` (e.g. a
6433
+ * CI-built image tagged by branch/sha). Itself a template over the provision vars.
6434
+ */
6435
+ readonly imageTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
6436
+ /** Fallback TTL (ms) after which the env is swept + torn down. */
6437
+ readonly defaultTtlMs: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.MinValueAction<number, 60000, undefined>]>, undefined>;
6438
+ /**
6439
+ * How long (seconds) the container deploy adapter waits for each Deployment to roll out
6440
+ * before reporting the env still `provisioning` (the backend keeps polling). Only the
6441
+ * container-backed render path honors it; absent ⇒ the harness default (180s).
6442
+ */
6443
+ readonly rolloutTimeoutSeconds: v.OptionalSchema<v.SchemaWithPipe<readonly [v.NumberSchema<undefined>, v.IntegerAction<number, undefined>, v.MinValueAction<number, 1, undefined>]>, undefined>;
6444
+ /** Extra labels stamped on the namespace + every applied resource. */
6445
+ readonly labels: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
6446
+ /** Extra annotations stamped on the namespace. */
6447
+ readonly annotations: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.StringSchema<undefined>, undefined>, undefined>;
6448
+ /** Structured image overrides (the kustomize `images:` shape), templated over provision vars. */
6449
+ readonly images: v.OptionalSchema<v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
6450
+ /** The image to match (the `name:` in a kustomization `images:` entry), e.g. `registry/app`. */
6451
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
6452
+ /** Optional replacement repo, templated; absent ⇒ keep the original repo. */
6453
+ readonly newNameTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
6454
+ /** Replacement tag, templated (e.g. `{{branch}}` / `{{sha}}`); mutually exclusive with digest. */
6455
+ readonly newTagTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
6456
+ /** Replacement digest, templated; alternative to a tag. */
6457
+ readonly digestTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
6458
+ }, undefined>, v.CheckAction<{
6459
+ name: string;
6460
+ newNameTemplate?: string | undefined;
6461
+ newTagTemplate?: string | undefined;
6462
+ digestTemplate?: string | undefined;
6463
+ }, "an image override must set at least one of newNameTemplate, newTagTemplate, or digestTemplate.">, v.CheckAction<{
6464
+ name: string;
6465
+ newNameTemplate?: string | undefined;
6466
+ newTagTemplate?: string | undefined;
6467
+ digestTemplate?: string | undefined;
6468
+ }, "newTagTemplate and digestTemplate are mutually exclusive on an image override.">]>, undefined>, undefined>;
6469
+ /** Helm releases to install — workspace-shared singletons merged with the service's per-env ones. */
6470
+ readonly helmReleases: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
6471
+ /** Release name. */
6472
+ readonly name: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
6473
+ /** Chart ref: an OCI ref (`oci://…`) or, with `repo`, a `repo/chart` name. */
6474
+ readonly chart: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
6475
+ /** Chart repo URL; absent ⇒ `chart` is an OCI ref. */
6476
+ readonly repo: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
6477
+ /** PINNED chart version, e.g. `1.2.3` / `v1.2.3` (floating tags like `latest`/`^1.0` rejected). */
6478
+ readonly version: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.RegexAction<string, "version must be a pinned semver (e.g. 1.2.3), not a floating tag like latest or ^1.0.">]>;
6479
+ /** Namespace to install into, templated; absent ⇒ the environment namespace. */
6480
+ readonly namespaceTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>, undefined>;
6481
+ /** Inline `--values` overrides. */
6482
+ readonly values: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.UnknownSchema, undefined>, undefined>;
6483
+ /** Templated `--set` overrides. */
6484
+ readonly set: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
6485
+ /** Dotted `--set` path, e.g. `config.rateLimit.enabled`. */
6486
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
6487
+ /** The value, templated over the provision vars. */
6488
+ readonly valueTemplate: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MaxLengthAction<string, 2000, undefined>]>;
6489
+ }, undefined>, undefined>, undefined>;
6490
+ /** Secret-bundle-backed values folded in at provision time (`--set <path>=<secret>`). */
6491
+ readonly valuesSecretRefs: v.OptionalSchema<v.ArraySchema<v.ObjectSchema<{
6492
+ readonly path: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
6493
+ readonly secretRef: v.ObjectSchema<{
6494
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
6495
+ }, undefined>;
6496
+ }, undefined>, undefined>, undefined>;
6497
+ readonly scope: v.OptionalSchema<v.PicklistSchema<["per-environment", "shared"], undefined>, undefined>;
6498
+ }, undefined>, undefined>, undefined>;
6499
+ /** Secrets fed in before apply (a `Secret` resource or a `secretGenerator` `.env`). */
6500
+ readonly secretInjections: v.OptionalSchema<v.ArraySchema<v.VariantSchema<"mode", [v.ObjectSchema<{
6501
+ readonly mode: v.LiteralSchema<"secret", undefined>;
6502
+ /** Target Secret name in the namespace. */
6503
+ readonly secretName: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>;
6504
+ /** Secret `type`; absent ⇒ `Opaque`. */
6505
+ readonly secretType: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>]>, undefined>;
6506
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
6507
+ /** Key inside the rendered Secret / `.env`. */
6508
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
6509
+ /** Resolve the value from the workspace encrypted bundle by key. */
6510
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
6511
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
6512
+ }, undefined>, undefined>;
6513
+ /** OR a non-secret value, templated over the provision vars. */
6514
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
6515
+ }, undefined>, v.CheckAction<{
6516
+ key: string;
6517
+ secretRef?: {
6518
+ key: string;
6519
+ } | undefined;
6520
+ valueTemplate?: string | undefined;
6521
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
6522
+ }, undefined>, v.ObjectSchema<{
6523
+ readonly mode: v.LiteralSchema<"generatorEnvFile", undefined>;
6524
+ /**
6525
+ * Repo-relative path within the overlay tree to write the `KEY=value` env file the
6526
+ * overlay's `secretGenerator` reads (e.g. `overlays/<env>/<component>/.env`). The
6527
+ * overlay names the Secret.
6528
+ */
6529
+ readonly envFilePath: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 500, undefined>]>;
6530
+ readonly entries: v.ArraySchema<v.SchemaWithPipe<readonly [v.ObjectSchema<{
6531
+ /** Key inside the rendered Secret / `.env`. */
6532
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 256, undefined>]>;
6533
+ /** Resolve the value from the workspace encrypted bundle by key. */
6534
+ readonly secretRef: v.OptionalSchema<v.ObjectSchema<{
6535
+ readonly key: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>]>;
6536
+ }, undefined>, undefined>;
6537
+ /** OR a non-secret value, templated over the provision vars. */
6538
+ readonly valueTemplate: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MaxLengthAction<string, 2000, undefined>]>, undefined>;
6539
+ }, undefined>, v.CheckAction<{
6540
+ key: string;
6541
+ secretRef?: {
6542
+ key: string;
6543
+ } | undefined;
6544
+ valueTemplate?: string | undefined;
6545
+ }, "a secret entry must set exactly one of secretRef or valueTemplate.">]>, undefined>;
6546
+ }, undefined>], undefined>, undefined>, undefined>;
6547
+ }, undefined>;
5638
6548
  }, undefined>, v.ObjectSchema<{
5639
6549
  readonly kind: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.TrimAction, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 64, undefined>, v.RegexAction<string, "must be a lower-kebab slug">, v.CheckAction<string, "reserved backend kind">]>;
5640
6550
  readonly manifest: v.ObjectSchema<{