UNPKG

@soft-stech/keda

Version:
109 lines (108 loc) 4.73 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ITriggerAuthenticationSchema = void 0; // Generated by ts-to-zod const zod_1 = require("zod"); const ObjectMeta_schema_1 = require("@soft-stech/apimachinery/apis/meta/v1/ObjectMeta.schema"); /** * TriggerAuthentication defines how a trigger can authenticate */ exports.ITriggerAuthenticationSchema = zod_1.z.object({ /** * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources */ "apiVersion": zod_1.z.literal("keda.sh/v1alpha1"), /** * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds */ "kind": zod_1.z.literal("TriggerAuthentication"), "metadata": ObjectMeta_schema_1.iObjectMetaSchema.optional(), /** * TriggerAuthenticationSpec defines the various ways to authenticate */ "spec": zod_1.z.object({ /** * AzureKeyVault is used to authenticate using Azure Key Vault */ "azureKeyVault": zod_1.z.object({ "cloud": zod_1.z.object({ "activeDirectoryEndpoint": zod_1.z.string().optional(), "keyVaultResourceURL": zod_1.z.string().optional(), "type": zod_1.z.string() }).optional(), "credentials": zod_1.z.object({ "clientId": zod_1.z.string(), "clientSecret": zod_1.z.object({ "valueFrom": zod_1.z.object({ "secretKeyRef": zod_1.z.object({ "key": zod_1.z.string(), "name": zod_1.z.string() }) }) }), "tenantId": zod_1.z.string() }).optional(), /** * AuthPodIdentity allows users to select the platform native identity mechanism */ "podIdentity": zod_1.z.object({ "identityId": zod_1.z.string().optional(), /** * PodIdentityProvider contains the list of providers */ "provider": zod_1.z.string() }).optional(), "secrets": zod_1.z.array(zod_1.z.object({ "name": zod_1.z.string(), "parameter": zod_1.z.string(), "version": zod_1.z.string().optional() })), "vaultUri": zod_1.z.string() }).optional(), "env": zod_1.z.array(zod_1.z.object({ "containerName": zod_1.z.string().optional(), "name": zod_1.z.string(), "parameter": zod_1.z.string() })).optional(), /** * HashiCorpVault is used to authenticate using Hashicorp Vault */ "hashiCorpVault": zod_1.z.object({ "address": zod_1.z.string(), /** * VaultAuthentication contains the list of Hashicorp Vault authentication methods */ "authentication": zod_1.z.string(), /** * Credential defines the Hashicorp Vault credentials depending on the authentication method */ "credential": zod_1.z.object({ "serviceAccount": zod_1.z.string().optional(), "token": zod_1.z.string().optional() }).optional(), "mount": zod_1.z.string().optional(), "namespace": zod_1.z.string().optional(), "role": zod_1.z.string().optional(), "secrets": zod_1.z.array(zod_1.z.object({ "key": zod_1.z.string(), "parameter": zod_1.z.string(), "path": zod_1.z.string() })) }).optional(), /** * AuthPodIdentity allows users to select the platform native identity mechanism */ "podIdentity": zod_1.z.object({ "identityId": zod_1.z.string().optional(), /** * PodIdentityProvider contains the list of providers */ "provider": zod_1.z.string() }).optional(), "secretTargetRef": zod_1.z.array(zod_1.z.object({ "key": zod_1.z.string(), "name": zod_1.z.string(), "parameter": zod_1.z.string() })).optional() }) });