From d014744b7f99778b63cdaabe03d28e88e102d4e1 Mon Sep 17 00:00:00 2001 From: Joy Liu <34288846+joyliu-q@users.noreply.github.com> Date: Wed, 25 Oct 2023 22:23:54 -0700 Subject: [PATCH] Persistent Redis (#177) * Add ConfigMap for Persistent Redis Configuration * Add initial changes needed * Update snapshots * i am but a servant to the great ol' Code Coverage * Cleanup * Snapshott * Failing chart test :D * Woooo * the anti-power of eunsoo shin * bet * lol * Better testing * Abstract away configmap interface * Update snapshot and naming conventions * Update host path * Update host path --- cdk/kittyhawk/.projenrc.js | 2 +- cdk/kittyhawk/LICENSE | 2 +- cdk/kittyhawk/package.json | 2 +- cdk/kittyhawk/src/application/redis.ts | 110 + cdk/kittyhawk/src/container.ts | 23 +- cdk/kittyhawk/src/deployment.ts | 17 +- cdk/kittyhawk/src/imports/k8s.ts | 13263 ++++++++++------ .../__snapshots__/application.test.ts.snap | 1371 -- .../test/__snapshots__/cronjob.test.ts.snap | 58 + .../__snapshots__/deployment.test.ts.snap | 138 + cdk/kittyhawk/test/application.test.ts | 192 - .../__snapshots__/application.test.ts.snap | 87 + .../__snapshots__/django.test.ts.snap | 604 + .../__snapshots__/react.test.ts.snap | 495 + .../__snapshots__/redis.test.ts.snap | 620 + .../test/application/application.test.ts | 24 + cdk/kittyhawk/test/application/django.test.ts | 76 + cdk/kittyhawk/test/application/react.test.ts | 53 + cdk/kittyhawk/test/application/redis.test.ts | 81 + cdk/kittyhawk/test/cronjob.test.ts | 19 +- cdk/kittyhawk/test/deployment.test.ts | 53 + cdk/kittyhawk/test/ingress.test.ts | 6 +- cdk/kittyhawk/test/utils.ts | 10 +- terraform/modules/base_cluster/redis.tf | 13 + 24 files changed, 11169 insertions(+), 6150 deletions(-) delete mode 100644 cdk/kittyhawk/test/__snapshots__/application.test.ts.snap create mode 100644 cdk/kittyhawk/test/__snapshots__/deployment.test.ts.snap delete mode 100644 cdk/kittyhawk/test/application.test.ts create mode 100644 cdk/kittyhawk/test/application/__snapshots__/application.test.ts.snap create mode 100644 cdk/kittyhawk/test/application/__snapshots__/django.test.ts.snap create mode 100644 cdk/kittyhawk/test/application/__snapshots__/react.test.ts.snap create mode 100644 cdk/kittyhawk/test/application/__snapshots__/redis.test.ts.snap create mode 100644 cdk/kittyhawk/test/application/application.test.ts create mode 100644 cdk/kittyhawk/test/application/django.test.ts create mode 100644 cdk/kittyhawk/test/application/react.test.ts create mode 100644 cdk/kittyhawk/test/application/redis.test.ts create mode 100644 cdk/kittyhawk/test/deployment.test.ts create mode 100644 terraform/modules/base_cluster/redis.tf diff --git a/cdk/kittyhawk/.projenrc.js b/cdk/kittyhawk/.projenrc.js index fbd49378..1ad4f333 100644 --- a/cdk/kittyhawk/.projenrc.js +++ b/cdk/kittyhawk/.projenrc.js @@ -16,7 +16,7 @@ const project = new TypeScriptProject({ }, }); -project.addFields({ ["version"]: "1.1.8" }); +project.addFields({ ["version"]: "1.1.9" }); project.prettier?.ignoreFile?.addPatterns("src/imports"); project.testTask.steps.forEach((step) => { if (step.exec) { diff --git a/cdk/kittyhawk/LICENSE b/cdk/kittyhawk/LICENSE index 54c994e3..9b853f6d 100644 --- a/cdk/kittyhawk/LICENSE +++ b/cdk/kittyhawk/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2022 Penn Labs +Copyright (c) 2023 Penn Labs Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/cdk/kittyhawk/package.json b/cdk/kittyhawk/package.json index 301e5ec3..ac1469ff 100644 --- a/cdk/kittyhawk/package.json +++ b/cdk/kittyhawk/package.json @@ -65,7 +65,7 @@ "main": "lib/index.js", "license": "MIT", "homepage": "https://kittyhawk.pennlabs.org", - "version": "1.1.8", + "version": "1.1.9", "jest": { "testMatch": [ "/src/**/__tests__/**/*.ts?(x)", diff --git a/cdk/kittyhawk/src/application/redis.ts b/cdk/kittyhawk/src/application/redis.ts index c8233b52..5cfea2c4 100644 --- a/cdk/kittyhawk/src/application/redis.ts +++ b/cdk/kittyhawk/src/application/redis.ts @@ -1,5 +1,11 @@ import { Construct } from "constructs"; import { DeploymentProps } from "../deployment"; +import { + KubeConfigMap, + KubePersistentVolume, + KubePersistentVolumeClaim, + Quantity, +} from "../imports/k8s"; import { Application } from "./base"; export interface RedisApplicationProps { @@ -20,6 +26,19 @@ export interface RedisApplicationProps { * serviceAccountName: release name */ readonly createServiceAccount?: boolean; + + /** + * Persists data to a volume, using a ConfigMap to decide where to mount it. + */ + readonly persistData?: boolean; + + /** + * Override the default redis ConfigMap configuration and creates a custom ConfigMap object. + */ + readonly redisConfigMap?: { + readonly name: string; + readonly config: string; + }; } export class RedisApplication extends Application { @@ -28,10 +47,101 @@ export class RedisApplication extends Application { appname: string, redisProps: RedisApplicationProps ) { + const CONFIG_MAP_NAME = "redis-config"; + const releaseName = process.env.RELEASE_NAME || "undefined_release"; + + // Persistence constants + const storageClassName = `${releaseName}-${appname}-storage`; + const pvName = `${releaseName}-${appname}-pv`; + const pvcName = `${releaseName}-${appname}-pvc`; + + if (redisProps.redisConfigMap) { + new KubeConfigMap(scope, redisProps.redisConfigMap.name, { + metadata: { + name: redisProps.redisConfigMap.name, + }, + data: { + "redis-config": redisProps.redisConfigMap.config, + }, + }); + } + + if (redisProps.persistData) { + new KubePersistentVolume(scope, pvName, { + metadata: { + name: pvName, + }, + spec: { + storageClassName, + accessModes: ["ReadWriteMany"], // TODO: ask Redis folks + capacity: { + storage: Quantity.fromString("1Gi"), + }, + hostPath: { + path: `/${releaseName}/redis`, + }, + }, + }); + new KubePersistentVolumeClaim(scope, pvcName, { + metadata: { + name: pvcName, + }, + spec: { + storageClassName, + accessModes: ["ReadWriteMany"], // TODO: ask Redis folks + resources: { + requests: { + storage: Quantity.fromString("1Gi"), + }, + }, + }, + }); + } + super(scope, appname, { deployment: { image: redisProps.deployment?.image ?? "redis", tag: redisProps.deployment?.tag ?? "6.0", + volumeMounts: [ + ...(redisProps.persistData + ? [ + { + name: "data", + mountPath: "/redis-master-data", + }, + { + name: "config", + mountPath: "/redis-master", + }, + ] + : []), + ...(redisProps.deployment?.volumeMounts ?? []), + ], + volumes: [ + ...(redisProps.persistData + ? [ + { + name: "data", + persistentVolumeClaim: { + claimName: pvcName, + }, + }, + { + name: "config", + configMap: { + name: redisProps.redisConfigMap?.name ?? CONFIG_MAP_NAME, + items: [ + { + key: "redis-config", + path: "redis.conf", + }, + ], + }, + }, + ] + : []), + ...(redisProps.deployment?.volumes ?? []), + ], ...redisProps.deployment, }, port: redisProps.port ?? 6379, diff --git a/cdk/kittyhawk/src/container.ts b/cdk/kittyhawk/src/container.ts index e88824c8..0833d0c4 100644 --- a/cdk/kittyhawk/src/container.ts +++ b/cdk/kittyhawk/src/container.ts @@ -62,6 +62,13 @@ export interface ContainerProps { */ readonly secretMounts?: VolumeMount[]; + /** + * Volume mounts for deployment container. + * + * @default [] + */ + readonly volumeMounts?: VolumeMount[]; + /** * Internal port. * @@ -165,10 +172,16 @@ export class Container implements ContainerInterface { : [{ containerPort: props.port ?? 80 }]; this.imagePullPolicy = props.pullPolicy || "IfNotPresent"; this.command = props.cmd; - this.volumeMounts = props.secretMounts?.map((vm) => ({ - ...vm, - name: secretVolumeName(vm), - })); + this.volumeMounts = [ + ...(props.secretMounts?.map((vm) => ({ + ...vm, + name: secretVolumeName(vm), + })) ?? []), + ...(props.volumeMounts || []), + ]; + if (this.volumeMounts.length === 0) { + this.volumeMounts = undefined; + } this.envFrom = props.secret ? [{ secretRef: { name: props.secret } }] : undefined; @@ -180,7 +193,7 @@ export class Container implements ContainerInterface { const secretVolumeName = (vm: VolumeMount) => { const mountString = (a: string) => a.toLowerCase().split("_").join("-"); return `${mountString(vm.name)}${ - vm.subPath && `-${mountString(vm.subPath)}` + vm.subPath ? `-${mountString(vm.subPath)}` : "" }`; }; export class SecretVolume implements VolumeInterface { diff --git a/cdk/kittyhawk/src/deployment.ts b/cdk/kittyhawk/src/deployment.ts index 60d1c857..bca18e24 100644 --- a/cdk/kittyhawk/src/deployment.ts +++ b/cdk/kittyhawk/src/deployment.ts @@ -5,6 +5,7 @@ import { KubeDeployment as DeploymentApiObject, KubeServiceAccount, VolumeMount, + Volume, } from "./imports/k8s"; import { defaultChildName } from "./utils"; @@ -23,6 +24,20 @@ export interface DeploymentProps extends ContainerProps { */ readonly secretMounts?: VolumeMount[]; + /** + * Volume mounts for deployment container. + * + * This appends to the existing list of volumes, if created by the `secretMounts` property. + * + * @default [] + */ + readonly volumeMounts?: VolumeMount[]; + + /** + * Volume mounts for deployment container. + */ + readonly volumes?: Volume[]; + /** * The service account to be used to attach to any deployment pods. * Default serviceAccountName: release name @@ -64,7 +79,7 @@ export class Deployment extends Construct { ? { serviceAccountName: props.serviceAccount.name } : {}), containers: containers, - volumes: secretVolumes, + volumes: [...secretVolumes, ...(props.volumes || [])], }, }, }, diff --git a/cdk/kittyhawk/src/imports/k8s.ts b/cdk/kittyhawk/src/imports/k8s.ts index 00696131..4a2e0d9e 100644 --- a/cdk/kittyhawk/src/imports/k8s.ts +++ b/cdk/kittyhawk/src/imports/k8s.ts @@ -1,6 +1,6 @@ // generated by cdk8s -import { ApiObject, GroupVersionKind } from 'cdk8s'; -import { Construct } from 'constructs'; +import { ApiObject, GroupVersionKind } from "cdk8s"; +import { Construct } from "constructs"; /** * MutatingWebhookConfiguration describes the configuration of and admission webhook that accept or reject and may change the object. @@ -12,9 +12,9 @@ export class KubeMutatingWebhookConfiguration extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.admissionregistration.v1.MutatingWebhookConfiguration" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'admissionregistration.k8s.io/v1', - kind: 'MutatingWebhookConfiguration', - } + apiVersion: "admissionregistration.k8s.io/v1", + kind: "MutatingWebhookConfiguration", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.admissionregistration.v1.MutatingWebhookConfiguration". @@ -23,7 +23,9 @@ export class KubeMutatingWebhookConfiguration extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeMutatingWebhookConfigurationProps = {}): any { + public static manifest( + props: KubeMutatingWebhookConfigurationProps = {} + ): any { return { ...KubeMutatingWebhookConfiguration.GVK, ...toJson_KubeMutatingWebhookConfigurationProps(props), @@ -36,7 +38,11 @@ export class KubeMutatingWebhookConfiguration extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeMutatingWebhookConfigurationProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeMutatingWebhookConfigurationProps = {} + ) { super(scope, id, { ...KubeMutatingWebhookConfiguration.GVK, ...props, @@ -66,9 +72,9 @@ export class KubeMutatingWebhookConfigurationList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.admissionregistration.v1.MutatingWebhookConfigurationList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'admissionregistration.k8s.io/v1', - kind: 'MutatingWebhookConfigurationList', - } + apiVersion: "admissionregistration.k8s.io/v1", + kind: "MutatingWebhookConfigurationList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.admissionregistration.v1.MutatingWebhookConfigurationList". @@ -77,7 +83,9 @@ export class KubeMutatingWebhookConfigurationList extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeMutatingWebhookConfigurationListProps): any { + public static manifest( + props: KubeMutatingWebhookConfigurationListProps + ): any { return { ...KubeMutatingWebhookConfigurationList.GVK, ...toJson_KubeMutatingWebhookConfigurationListProps(props), @@ -90,7 +98,11 @@ export class KubeMutatingWebhookConfigurationList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeMutatingWebhookConfigurationListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeMutatingWebhookConfigurationListProps + ) { super(scope, id, { ...KubeMutatingWebhookConfigurationList.GVK, ...props, @@ -120,9 +132,9 @@ export class KubeValidatingWebhookConfiguration extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.admissionregistration.v1.ValidatingWebhookConfiguration" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'admissionregistration.k8s.io/v1', - kind: 'ValidatingWebhookConfiguration', - } + apiVersion: "admissionregistration.k8s.io/v1", + kind: "ValidatingWebhookConfiguration", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.admissionregistration.v1.ValidatingWebhookConfiguration". @@ -131,7 +143,9 @@ export class KubeValidatingWebhookConfiguration extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeValidatingWebhookConfigurationProps = {}): any { + public static manifest( + props: KubeValidatingWebhookConfigurationProps = {} + ): any { return { ...KubeValidatingWebhookConfiguration.GVK, ...toJson_KubeValidatingWebhookConfigurationProps(props), @@ -144,7 +158,11 @@ export class KubeValidatingWebhookConfiguration extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeValidatingWebhookConfigurationProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeValidatingWebhookConfigurationProps = {} + ) { super(scope, id, { ...KubeValidatingWebhookConfiguration.GVK, ...props, @@ -174,9 +192,9 @@ export class KubeValidatingWebhookConfigurationList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.admissionregistration.v1.ValidatingWebhookConfigurationList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'admissionregistration.k8s.io/v1', - kind: 'ValidatingWebhookConfigurationList', - } + apiVersion: "admissionregistration.k8s.io/v1", + kind: "ValidatingWebhookConfigurationList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.admissionregistration.v1.ValidatingWebhookConfigurationList". @@ -185,7 +203,9 @@ export class KubeValidatingWebhookConfigurationList extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeValidatingWebhookConfigurationListProps): any { + public static manifest( + props: KubeValidatingWebhookConfigurationListProps + ): any { return { ...KubeValidatingWebhookConfigurationList.GVK, ...toJson_KubeValidatingWebhookConfigurationListProps(props), @@ -198,7 +218,11 @@ export class KubeValidatingWebhookConfigurationList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeValidatingWebhookConfigurationListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeValidatingWebhookConfigurationListProps + ) { super(scope, id, { ...KubeValidatingWebhookConfigurationList.GVK, ...props, @@ -228,9 +252,9 @@ export class KubeMutatingWebhookConfigurationV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.admissionregistration.v1beta1.MutatingWebhookConfiguration" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'admissionregistration.k8s.io/v1', - kind: 'MutatingWebhookConfiguration', - } + apiVersion: "admissionregistration.k8s.io/v1", + kind: "MutatingWebhookConfiguration", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.admissionregistration.v1beta1.MutatingWebhookConfiguration". @@ -239,7 +263,9 @@ export class KubeMutatingWebhookConfigurationV1Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeMutatingWebhookConfigurationV1Beta1Props = {}): any { + public static manifest( + props: KubeMutatingWebhookConfigurationV1Beta1Props = {} + ): any { return { ...KubeMutatingWebhookConfigurationV1Beta1.GVK, ...toJson_KubeMutatingWebhookConfigurationV1Beta1Props(props), @@ -252,7 +278,11 @@ export class KubeMutatingWebhookConfigurationV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeMutatingWebhookConfigurationV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeMutatingWebhookConfigurationV1Beta1Props = {} + ) { super(scope, id, { ...KubeMutatingWebhookConfigurationV1Beta1.GVK, ...props, @@ -282,9 +312,9 @@ export class KubeMutatingWebhookConfigurationListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.admissionregistration.v1beta1.MutatingWebhookConfigurationList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'admissionregistration.k8s.io/v1', - kind: 'MutatingWebhookConfigurationList', - } + apiVersion: "admissionregistration.k8s.io/v1", + kind: "MutatingWebhookConfigurationList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.admissionregistration.v1beta1.MutatingWebhookConfigurationList". @@ -293,7 +323,9 @@ export class KubeMutatingWebhookConfigurationListV1Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeMutatingWebhookConfigurationListV1Beta1Props): any { + public static manifest( + props: KubeMutatingWebhookConfigurationListV1Beta1Props + ): any { return { ...KubeMutatingWebhookConfigurationListV1Beta1.GVK, ...toJson_KubeMutatingWebhookConfigurationListV1Beta1Props(props), @@ -306,7 +338,11 @@ export class KubeMutatingWebhookConfigurationListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeMutatingWebhookConfigurationListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeMutatingWebhookConfigurationListV1Beta1Props + ) { super(scope, id, { ...KubeMutatingWebhookConfigurationListV1Beta1.GVK, ...props, @@ -336,9 +372,9 @@ export class KubeValidatingWebhookConfigurationV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.admissionregistration.v1beta1.ValidatingWebhookConfiguration" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'admissionregistration.k8s.io/v1', - kind: 'ValidatingWebhookConfiguration', - } + apiVersion: "admissionregistration.k8s.io/v1", + kind: "ValidatingWebhookConfiguration", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.admissionregistration.v1beta1.ValidatingWebhookConfiguration". @@ -347,7 +383,9 @@ export class KubeValidatingWebhookConfigurationV1Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeValidatingWebhookConfigurationV1Beta1Props = {}): any { + public static manifest( + props: KubeValidatingWebhookConfigurationV1Beta1Props = {} + ): any { return { ...KubeValidatingWebhookConfigurationV1Beta1.GVK, ...toJson_KubeValidatingWebhookConfigurationV1Beta1Props(props), @@ -360,7 +398,11 @@ export class KubeValidatingWebhookConfigurationV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeValidatingWebhookConfigurationV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeValidatingWebhookConfigurationV1Beta1Props = {} + ) { super(scope, id, { ...KubeValidatingWebhookConfigurationV1Beta1.GVK, ...props, @@ -390,9 +432,9 @@ export class KubeValidatingWebhookConfigurationListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.admissionregistration.v1beta1.ValidatingWebhookConfigurationList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'admissionregistration.k8s.io/v1', - kind: 'ValidatingWebhookConfigurationList', - } + apiVersion: "admissionregistration.k8s.io/v1", + kind: "ValidatingWebhookConfigurationList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.admissionregistration.v1beta1.ValidatingWebhookConfigurationList". @@ -401,7 +443,9 @@ export class KubeValidatingWebhookConfigurationListV1Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeValidatingWebhookConfigurationListV1Beta1Props): any { + public static manifest( + props: KubeValidatingWebhookConfigurationListV1Beta1Props + ): any { return { ...KubeValidatingWebhookConfigurationListV1Beta1.GVK, ...toJson_KubeValidatingWebhookConfigurationListV1Beta1Props(props), @@ -414,7 +458,11 @@ export class KubeValidatingWebhookConfigurationListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeValidatingWebhookConfigurationListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeValidatingWebhookConfigurationListV1Beta1Props + ) { super(scope, id, { ...KubeValidatingWebhookConfigurationListV1Beta1.GVK, ...props, @@ -445,9 +493,9 @@ export class KubeStorageVersionV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apiserverinternal.v1alpha1.StorageVersion" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'internal.apiserver.k8s.io/v1alpha1', - kind: 'StorageVersion', - } + apiVersion: "internal.apiserver.k8s.io/v1alpha1", + kind: "StorageVersion", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apiserverinternal.v1alpha1.StorageVersion". @@ -469,7 +517,11 @@ export class KubeStorageVersionV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeStorageVersionV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeStorageVersionV1Alpha1Props + ) { super(scope, id, { ...KubeStorageVersionV1Alpha1.GVK, ...props, @@ -499,9 +551,9 @@ export class KubeStorageVersionListV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apiserverinternal.v1alpha1.StorageVersionList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'internal.apiserver.k8s.io/v1alpha1', - kind: 'StorageVersionList', - } + apiVersion: "internal.apiserver.k8s.io/v1alpha1", + kind: "StorageVersionList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apiserverinternal.v1alpha1.StorageVersionList". @@ -523,7 +575,11 @@ export class KubeStorageVersionListV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeStorageVersionListV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeStorageVersionListV1Alpha1Props + ) { super(scope, id, { ...KubeStorageVersionListV1Alpha1.GVK, ...props, @@ -553,9 +609,9 @@ export class KubeControllerRevision extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.ControllerRevision" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'ControllerRevision', - } + apiVersion: "apps/v1", + kind: "ControllerRevision", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.ControllerRevision". @@ -577,7 +633,11 @@ export class KubeControllerRevision extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeControllerRevisionProps) { + public constructor( + scope: Construct, + id: string, + props: KubeControllerRevisionProps + ) { super(scope, id, { ...KubeControllerRevision.GVK, ...props, @@ -607,9 +667,9 @@ export class KubeControllerRevisionList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.ControllerRevisionList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'ControllerRevisionList', - } + apiVersion: "apps/v1", + kind: "ControllerRevisionList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.ControllerRevisionList". @@ -631,7 +691,11 @@ export class KubeControllerRevisionList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeControllerRevisionListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeControllerRevisionListProps + ) { super(scope, id, { ...KubeControllerRevisionList.GVK, ...props, @@ -661,9 +725,9 @@ export class KubeDaemonSet extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.DaemonSet" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'DaemonSet', - } + apiVersion: "apps/v1", + kind: "DaemonSet", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.DaemonSet". @@ -685,7 +749,11 @@ export class KubeDaemonSet extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeDaemonSetProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeDaemonSetProps = {} + ) { super(scope, id, { ...KubeDaemonSet.GVK, ...props, @@ -715,9 +783,9 @@ export class KubeDaemonSetList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.DaemonSetList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'DaemonSetList', - } + apiVersion: "apps/v1", + kind: "DaemonSetList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.DaemonSetList". @@ -739,7 +807,11 @@ export class KubeDaemonSetList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeDaemonSetListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeDaemonSetListProps + ) { super(scope, id, { ...KubeDaemonSetList.GVK, ...props, @@ -769,9 +841,9 @@ export class KubeDeployment extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.Deployment" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'Deployment', - } + apiVersion: "apps/v1", + kind: "Deployment", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.Deployment". @@ -793,7 +865,11 @@ export class KubeDeployment extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeDeploymentProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeDeploymentProps = {} + ) { super(scope, id, { ...KubeDeployment.GVK, ...props, @@ -823,9 +899,9 @@ export class KubeDeploymentList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.DeploymentList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'DeploymentList', - } + apiVersion: "apps/v1", + kind: "DeploymentList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.DeploymentList". @@ -847,7 +923,11 @@ export class KubeDeploymentList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeDeploymentListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeDeploymentListProps + ) { super(scope, id, { ...KubeDeploymentList.GVK, ...props, @@ -877,9 +957,9 @@ export class KubeReplicaSet extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.ReplicaSet" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'ReplicaSet', - } + apiVersion: "apps/v1", + kind: "ReplicaSet", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.ReplicaSet". @@ -901,7 +981,11 @@ export class KubeReplicaSet extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeReplicaSetProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeReplicaSetProps = {} + ) { super(scope, id, { ...KubeReplicaSet.GVK, ...props, @@ -931,9 +1015,9 @@ export class KubeReplicaSetList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.ReplicaSetList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'ReplicaSetList', - } + apiVersion: "apps/v1", + kind: "ReplicaSetList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.ReplicaSetList". @@ -955,7 +1039,11 @@ export class KubeReplicaSetList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeReplicaSetListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeReplicaSetListProps + ) { super(scope, id, { ...KubeReplicaSetList.GVK, ...props, @@ -988,9 +1076,9 @@ export class KubeStatefulSet extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.StatefulSet" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'StatefulSet', - } + apiVersion: "apps/v1", + kind: "StatefulSet", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.StatefulSet". @@ -1012,7 +1100,11 @@ export class KubeStatefulSet extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeStatefulSetProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeStatefulSetProps = {} + ) { super(scope, id, { ...KubeStatefulSet.GVK, ...props, @@ -1042,9 +1134,9 @@ export class KubeStatefulSetList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.apps.v1.StatefulSetList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apps/v1', - kind: 'StatefulSetList', - } + apiVersion: "apps/v1", + kind: "StatefulSetList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.apps.v1.StatefulSetList". @@ -1066,7 +1158,11 @@ export class KubeStatefulSetList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeStatefulSetListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeStatefulSetListProps + ) { super(scope, id, { ...KubeStatefulSetList.GVK, ...props, @@ -1096,9 +1192,9 @@ export class KubeTokenRequest extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authentication.v1.TokenRequest" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authentication.k8s.io/v1', - kind: 'TokenRequest', - } + apiVersion: "authentication.k8s.io/v1", + kind: "TokenRequest", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authentication.v1.TokenRequest". @@ -1120,7 +1216,11 @@ export class KubeTokenRequest extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeTokenRequestProps) { + public constructor( + scope: Construct, + id: string, + props: KubeTokenRequestProps + ) { super(scope, id, { ...KubeTokenRequest.GVK, ...props, @@ -1150,9 +1250,9 @@ export class KubeTokenReview extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authentication.v1.TokenReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authentication.k8s.io/v1', - kind: 'TokenReview', - } + apiVersion: "authentication.k8s.io/v1", + kind: "TokenReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authentication.v1.TokenReview". @@ -1174,7 +1274,11 @@ export class KubeTokenReview extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeTokenReviewProps) { + public constructor( + scope: Construct, + id: string, + props: KubeTokenReviewProps + ) { super(scope, id, { ...KubeTokenReview.GVK, ...props, @@ -1204,9 +1308,9 @@ export class KubeTokenReviewV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authentication.v1beta1.TokenReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authentication.k8s.io/v1', - kind: 'TokenReview', - } + apiVersion: "authentication.k8s.io/v1", + kind: "TokenReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authentication.v1beta1.TokenReview". @@ -1228,7 +1332,11 @@ export class KubeTokenReviewV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeTokenReviewV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeTokenReviewV1Beta1Props + ) { super(scope, id, { ...KubeTokenReviewV1Beta1.GVK, ...props, @@ -1258,9 +1366,9 @@ export class KubeLocalSubjectAccessReview extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authorization.v1.LocalSubjectAccessReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authorization.k8s.io/v1', - kind: 'LocalSubjectAccessReview', - } + apiVersion: "authorization.k8s.io/v1", + kind: "LocalSubjectAccessReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authorization.v1.LocalSubjectAccessReview". @@ -1282,7 +1390,11 @@ export class KubeLocalSubjectAccessReview extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeLocalSubjectAccessReviewProps) { + public constructor( + scope: Construct, + id: string, + props: KubeLocalSubjectAccessReviewProps + ) { super(scope, id, { ...KubeLocalSubjectAccessReview.GVK, ...props, @@ -1312,9 +1424,9 @@ export class KubeSelfSubjectAccessReview extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authorization.v1.SelfSubjectAccessReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authorization.k8s.io/v1', - kind: 'SelfSubjectAccessReview', - } + apiVersion: "authorization.k8s.io/v1", + kind: "SelfSubjectAccessReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authorization.v1.SelfSubjectAccessReview". @@ -1336,7 +1448,11 @@ export class KubeSelfSubjectAccessReview extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeSelfSubjectAccessReviewProps) { + public constructor( + scope: Construct, + id: string, + props: KubeSelfSubjectAccessReviewProps + ) { super(scope, id, { ...KubeSelfSubjectAccessReview.GVK, ...props, @@ -1366,9 +1482,9 @@ export class KubeSelfSubjectRulesReview extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authorization.v1.SelfSubjectRulesReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authorization.k8s.io/v1', - kind: 'SelfSubjectRulesReview', - } + apiVersion: "authorization.k8s.io/v1", + kind: "SelfSubjectRulesReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authorization.v1.SelfSubjectRulesReview". @@ -1390,7 +1506,11 @@ export class KubeSelfSubjectRulesReview extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeSelfSubjectRulesReviewProps) { + public constructor( + scope: Construct, + id: string, + props: KubeSelfSubjectRulesReviewProps + ) { super(scope, id, { ...KubeSelfSubjectRulesReview.GVK, ...props, @@ -1420,9 +1540,9 @@ export class KubeSubjectAccessReview extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authorization.v1.SubjectAccessReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authorization.k8s.io/v1', - kind: 'SubjectAccessReview', - } + apiVersion: "authorization.k8s.io/v1", + kind: "SubjectAccessReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authorization.v1.SubjectAccessReview". @@ -1444,7 +1564,11 @@ export class KubeSubjectAccessReview extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeSubjectAccessReviewProps) { + public constructor( + scope: Construct, + id: string, + props: KubeSubjectAccessReviewProps + ) { super(scope, id, { ...KubeSubjectAccessReview.GVK, ...props, @@ -1474,9 +1598,9 @@ export class KubeLocalSubjectAccessReviewV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authorization.v1beta1.LocalSubjectAccessReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authorization.k8s.io/v1', - kind: 'LocalSubjectAccessReview', - } + apiVersion: "authorization.k8s.io/v1", + kind: "LocalSubjectAccessReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authorization.v1beta1.LocalSubjectAccessReview". @@ -1498,7 +1622,11 @@ export class KubeLocalSubjectAccessReviewV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeLocalSubjectAccessReviewV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeLocalSubjectAccessReviewV1Beta1Props + ) { super(scope, id, { ...KubeLocalSubjectAccessReviewV1Beta1.GVK, ...props, @@ -1528,9 +1656,9 @@ export class KubeSelfSubjectAccessReviewV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authorization.v1beta1.SelfSubjectAccessReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authorization.k8s.io/v1', - kind: 'SelfSubjectAccessReview', - } + apiVersion: "authorization.k8s.io/v1", + kind: "SelfSubjectAccessReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authorization.v1beta1.SelfSubjectAccessReview". @@ -1552,7 +1680,11 @@ export class KubeSelfSubjectAccessReviewV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeSelfSubjectAccessReviewV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeSelfSubjectAccessReviewV1Beta1Props + ) { super(scope, id, { ...KubeSelfSubjectAccessReviewV1Beta1.GVK, ...props, @@ -1582,9 +1714,9 @@ export class KubeSelfSubjectRulesReviewV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authorization.v1beta1.SelfSubjectRulesReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authorization.k8s.io/v1', - kind: 'SelfSubjectRulesReview', - } + apiVersion: "authorization.k8s.io/v1", + kind: "SelfSubjectRulesReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authorization.v1beta1.SelfSubjectRulesReview". @@ -1606,7 +1738,11 @@ export class KubeSelfSubjectRulesReviewV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeSelfSubjectRulesReviewV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeSelfSubjectRulesReviewV1Beta1Props + ) { super(scope, id, { ...KubeSelfSubjectRulesReviewV1Beta1.GVK, ...props, @@ -1636,9 +1772,9 @@ export class KubeSubjectAccessReviewV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.authorization.v1beta1.SubjectAccessReview" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'authorization.k8s.io/v1', - kind: 'SubjectAccessReview', - } + apiVersion: "authorization.k8s.io/v1", + kind: "SubjectAccessReview", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.authorization.v1beta1.SubjectAccessReview". @@ -1660,7 +1796,11 @@ export class KubeSubjectAccessReviewV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeSubjectAccessReviewV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeSubjectAccessReviewV1Beta1Props + ) { super(scope, id, { ...KubeSubjectAccessReviewV1Beta1.GVK, ...props, @@ -1690,9 +1830,9 @@ export class KubeHorizontalPodAutoscaler extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.autoscaling.v1.HorizontalPodAutoscaler" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'autoscaling/v1', - kind: 'HorizontalPodAutoscaler', - } + apiVersion: "autoscaling/v1", + kind: "HorizontalPodAutoscaler", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.autoscaling.v1.HorizontalPodAutoscaler". @@ -1714,7 +1854,11 @@ export class KubeHorizontalPodAutoscaler extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeHorizontalPodAutoscalerProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeHorizontalPodAutoscalerProps = {} + ) { super(scope, id, { ...KubeHorizontalPodAutoscaler.GVK, ...props, @@ -1744,9 +1888,9 @@ export class KubeHorizontalPodAutoscalerList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.autoscaling.v1.HorizontalPodAutoscalerList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'autoscaling/v1', - kind: 'HorizontalPodAutoscalerList', - } + apiVersion: "autoscaling/v1", + kind: "HorizontalPodAutoscalerList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.autoscaling.v1.HorizontalPodAutoscalerList". @@ -1768,7 +1912,11 @@ export class KubeHorizontalPodAutoscalerList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeHorizontalPodAutoscalerListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeHorizontalPodAutoscalerListProps + ) { super(scope, id, { ...KubeHorizontalPodAutoscalerList.GVK, ...props, @@ -1798,9 +1946,9 @@ export class KubeScale extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.autoscaling.v1.Scale" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'autoscaling/v1', - kind: 'Scale', - } + apiVersion: "autoscaling/v1", + kind: "Scale", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.autoscaling.v1.Scale". @@ -1852,9 +2000,9 @@ export class KubeHorizontalPodAutoscalerV2Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.autoscaling.v2beta1.HorizontalPodAutoscaler" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'autoscaling/v2beta1', - kind: 'HorizontalPodAutoscaler', - } + apiVersion: "autoscaling/v2beta1", + kind: "HorizontalPodAutoscaler", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.autoscaling.v2beta1.HorizontalPodAutoscaler". @@ -1863,7 +2011,9 @@ export class KubeHorizontalPodAutoscalerV2Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeHorizontalPodAutoscalerV2Beta1Props = {}): any { + public static manifest( + props: KubeHorizontalPodAutoscalerV2Beta1Props = {} + ): any { return { ...KubeHorizontalPodAutoscalerV2Beta1.GVK, ...toJson_KubeHorizontalPodAutoscalerV2Beta1Props(props), @@ -1876,7 +2026,11 @@ export class KubeHorizontalPodAutoscalerV2Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeHorizontalPodAutoscalerV2Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeHorizontalPodAutoscalerV2Beta1Props = {} + ) { super(scope, id, { ...KubeHorizontalPodAutoscalerV2Beta1.GVK, ...props, @@ -1906,9 +2060,9 @@ export class KubeHorizontalPodAutoscalerListV2Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.autoscaling.v2beta1.HorizontalPodAutoscalerList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'autoscaling/v2beta1', - kind: 'HorizontalPodAutoscalerList', - } + apiVersion: "autoscaling/v2beta1", + kind: "HorizontalPodAutoscalerList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.autoscaling.v2beta1.HorizontalPodAutoscalerList". @@ -1917,7 +2071,9 @@ export class KubeHorizontalPodAutoscalerListV2Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeHorizontalPodAutoscalerListV2Beta1Props): any { + public static manifest( + props: KubeHorizontalPodAutoscalerListV2Beta1Props + ): any { return { ...KubeHorizontalPodAutoscalerListV2Beta1.GVK, ...toJson_KubeHorizontalPodAutoscalerListV2Beta1Props(props), @@ -1930,7 +2086,11 @@ export class KubeHorizontalPodAutoscalerListV2Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeHorizontalPodAutoscalerListV2Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeHorizontalPodAutoscalerListV2Beta1Props + ) { super(scope, id, { ...KubeHorizontalPodAutoscalerListV2Beta1.GVK, ...props, @@ -1960,9 +2120,9 @@ export class KubeHorizontalPodAutoscalerV2Beta2 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.autoscaling.v2beta2.HorizontalPodAutoscaler" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'autoscaling/v2beta2', - kind: 'HorizontalPodAutoscaler', - } + apiVersion: "autoscaling/v2beta2", + kind: "HorizontalPodAutoscaler", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.autoscaling.v2beta2.HorizontalPodAutoscaler". @@ -1971,7 +2131,9 @@ export class KubeHorizontalPodAutoscalerV2Beta2 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeHorizontalPodAutoscalerV2Beta2Props = {}): any { + public static manifest( + props: KubeHorizontalPodAutoscalerV2Beta2Props = {} + ): any { return { ...KubeHorizontalPodAutoscalerV2Beta2.GVK, ...toJson_KubeHorizontalPodAutoscalerV2Beta2Props(props), @@ -1984,7 +2146,11 @@ export class KubeHorizontalPodAutoscalerV2Beta2 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeHorizontalPodAutoscalerV2Beta2Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeHorizontalPodAutoscalerV2Beta2Props = {} + ) { super(scope, id, { ...KubeHorizontalPodAutoscalerV2Beta2.GVK, ...props, @@ -2014,9 +2180,9 @@ export class KubeHorizontalPodAutoscalerListV2Beta2 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.autoscaling.v2beta2.HorizontalPodAutoscalerList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'autoscaling/v2beta2', - kind: 'HorizontalPodAutoscalerList', - } + apiVersion: "autoscaling/v2beta2", + kind: "HorizontalPodAutoscalerList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.autoscaling.v2beta2.HorizontalPodAutoscalerList". @@ -2025,7 +2191,9 @@ export class KubeHorizontalPodAutoscalerListV2Beta2 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeHorizontalPodAutoscalerListV2Beta2Props): any { + public static manifest( + props: KubeHorizontalPodAutoscalerListV2Beta2Props + ): any { return { ...KubeHorizontalPodAutoscalerListV2Beta2.GVK, ...toJson_KubeHorizontalPodAutoscalerListV2Beta2Props(props), @@ -2038,7 +2206,11 @@ export class KubeHorizontalPodAutoscalerListV2Beta2 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeHorizontalPodAutoscalerListV2Beta2Props) { + public constructor( + scope: Construct, + id: string, + props: KubeHorizontalPodAutoscalerListV2Beta2Props + ) { super(scope, id, { ...KubeHorizontalPodAutoscalerListV2Beta2.GVK, ...props, @@ -2068,9 +2240,9 @@ export class KubeCronJob extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.batch.v1.CronJob" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'batch/v1', - kind: 'CronJob', - } + apiVersion: "batch/v1", + kind: "CronJob", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.batch.v1.CronJob". @@ -2092,7 +2264,11 @@ export class KubeCronJob extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCronJobProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeCronJobProps = {} + ) { super(scope, id, { ...KubeCronJob.GVK, ...props, @@ -2122,9 +2298,9 @@ export class KubeCronJobList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.batch.v1.CronJobList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'batch/v1', - kind: 'CronJobList', - } + apiVersion: "batch/v1", + kind: "CronJobList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.batch.v1.CronJobList". @@ -2146,7 +2322,11 @@ export class KubeCronJobList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCronJobListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeCronJobListProps + ) { super(scope, id, { ...KubeCronJobList.GVK, ...props, @@ -2176,9 +2356,9 @@ export class KubeJob extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.batch.v1.Job" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'batch/v1', - kind: 'Job', - } + apiVersion: "batch/v1", + kind: "Job", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.batch.v1.Job". @@ -2230,9 +2410,9 @@ export class KubeJobList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.batch.v1.JobList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'batch/v1', - kind: 'JobList', - } + apiVersion: "batch/v1", + kind: "JobList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.batch.v1.JobList". @@ -2284,9 +2464,9 @@ export class KubeCronJobV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.batch.v1beta1.CronJob" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'batch/v1beta1', - kind: 'CronJob', - } + apiVersion: "batch/v1beta1", + kind: "CronJob", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.batch.v1beta1.CronJob". @@ -2308,7 +2488,11 @@ export class KubeCronJobV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCronJobV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeCronJobV1Beta1Props = {} + ) { super(scope, id, { ...KubeCronJobV1Beta1.GVK, ...props, @@ -2338,9 +2522,9 @@ export class KubeCronJobListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.batch.v1beta1.CronJobList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'batch/v1beta1', - kind: 'CronJobList', - } + apiVersion: "batch/v1beta1", + kind: "CronJobList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.batch.v1beta1.CronJobList". @@ -2362,7 +2546,11 @@ export class KubeCronJobListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCronJobListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCronJobListV1Beta1Props + ) { super(scope, id, { ...KubeCronJobListV1Beta1.GVK, ...props, @@ -2398,9 +2586,9 @@ export class KubeCertificateSigningRequest extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.certificates.v1.CertificateSigningRequest" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'certificates.k8s.io/v1', - kind: 'CertificateSigningRequest', - } + apiVersion: "certificates.k8s.io/v1", + kind: "CertificateSigningRequest", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.certificates.v1.CertificateSigningRequest". @@ -2422,7 +2610,11 @@ export class KubeCertificateSigningRequest extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCertificateSigningRequestProps) { + public constructor( + scope: Construct, + id: string, + props: KubeCertificateSigningRequestProps + ) { super(scope, id, { ...KubeCertificateSigningRequest.GVK, ...props, @@ -2452,9 +2644,9 @@ export class KubeCertificateSigningRequestList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.certificates.v1.CertificateSigningRequestList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'certificates.k8s.io/v1', - kind: 'CertificateSigningRequestList', - } + apiVersion: "certificates.k8s.io/v1", + kind: "CertificateSigningRequestList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.certificates.v1.CertificateSigningRequestList". @@ -2476,7 +2668,11 @@ export class KubeCertificateSigningRequestList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCertificateSigningRequestListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeCertificateSigningRequestListProps + ) { super(scope, id, { ...KubeCertificateSigningRequestList.GVK, ...props, @@ -2506,9 +2702,9 @@ export class KubeCertificateSigningRequestV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.certificates.v1beta1.CertificateSigningRequest" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'certificates.k8s.io/v1', - kind: 'CertificateSigningRequest', - } + apiVersion: "certificates.k8s.io/v1", + kind: "CertificateSigningRequest", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.certificates.v1beta1.CertificateSigningRequest". @@ -2517,7 +2713,9 @@ export class KubeCertificateSigningRequestV1Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeCertificateSigningRequestV1Beta1Props = {}): any { + public static manifest( + props: KubeCertificateSigningRequestV1Beta1Props = {} + ): any { return { ...KubeCertificateSigningRequestV1Beta1.GVK, ...toJson_KubeCertificateSigningRequestV1Beta1Props(props), @@ -2530,7 +2728,11 @@ export class KubeCertificateSigningRequestV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCertificateSigningRequestV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeCertificateSigningRequestV1Beta1Props = {} + ) { super(scope, id, { ...KubeCertificateSigningRequestV1Beta1.GVK, ...props, @@ -2560,9 +2762,9 @@ export class KubeCertificateSigningRequestListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.certificates.v1beta1.CertificateSigningRequestList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'certificates.k8s.io/v1', - kind: 'CertificateSigningRequestList', - } + apiVersion: "certificates.k8s.io/v1", + kind: "CertificateSigningRequestList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.certificates.v1beta1.CertificateSigningRequestList". @@ -2571,7 +2773,9 @@ export class KubeCertificateSigningRequestListV1Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeCertificateSigningRequestListV1Beta1Props): any { + public static manifest( + props: KubeCertificateSigningRequestListV1Beta1Props + ): any { return { ...KubeCertificateSigningRequestListV1Beta1.GVK, ...toJson_KubeCertificateSigningRequestListV1Beta1Props(props), @@ -2584,7 +2788,11 @@ export class KubeCertificateSigningRequestListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCertificateSigningRequestListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCertificateSigningRequestListV1Beta1Props + ) { super(scope, id, { ...KubeCertificateSigningRequestListV1Beta1.GVK, ...props, @@ -2614,9 +2822,9 @@ export class KubeLease extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.coordination.v1.Lease" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'coordination.k8s.io/v1', - kind: 'Lease', - } + apiVersion: "coordination.k8s.io/v1", + kind: "Lease", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.coordination.v1.Lease". @@ -2668,9 +2876,9 @@ export class KubeLeaseList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.coordination.v1.LeaseList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'coordination.k8s.io/v1', - kind: 'LeaseList', - } + apiVersion: "coordination.k8s.io/v1", + kind: "LeaseList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.coordination.v1.LeaseList". @@ -2722,9 +2930,9 @@ export class KubeLeaseV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.coordination.v1beta1.Lease" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'coordination.k8s.io/v1', - kind: 'Lease', - } + apiVersion: "coordination.k8s.io/v1", + kind: "Lease", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.coordination.v1beta1.Lease". @@ -2746,7 +2954,11 @@ export class KubeLeaseV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeLeaseV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeLeaseV1Beta1Props = {} + ) { super(scope, id, { ...KubeLeaseV1Beta1.GVK, ...props, @@ -2776,9 +2988,9 @@ export class KubeLeaseListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.coordination.v1beta1.LeaseList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'coordination.k8s.io/v1', - kind: 'LeaseList', - } + apiVersion: "coordination.k8s.io/v1", + kind: "LeaseList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.coordination.v1beta1.LeaseList". @@ -2800,7 +3012,11 @@ export class KubeLeaseListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeLeaseListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeLeaseListV1Beta1Props + ) { super(scope, id, { ...KubeLeaseListV1Beta1.GVK, ...props, @@ -2830,9 +3046,9 @@ export class KubeBinding extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.Binding" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'Binding', - } + apiVersion: "v1", + kind: "Binding", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.Binding". @@ -2884,9 +3100,9 @@ export class KubeComponentStatus extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ComponentStatus" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ComponentStatus', - } + apiVersion: "v1", + kind: "ComponentStatus", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ComponentStatus". @@ -2908,7 +3124,11 @@ export class KubeComponentStatus extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeComponentStatusProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeComponentStatusProps = {} + ) { super(scope, id, { ...KubeComponentStatus.GVK, ...props, @@ -2938,9 +3158,9 @@ export class KubeComponentStatusList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ComponentStatusList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ComponentStatusList', - } + apiVersion: "v1", + kind: "ComponentStatusList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ComponentStatusList". @@ -2962,7 +3182,11 @@ export class KubeComponentStatusList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeComponentStatusListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeComponentStatusListProps + ) { super(scope, id, { ...KubeComponentStatusList.GVK, ...props, @@ -2992,9 +3216,9 @@ export class KubeConfigMap extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ConfigMap" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ConfigMap', - } + apiVersion: "v1", + kind: "ConfigMap", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ConfigMap". @@ -3016,7 +3240,11 @@ export class KubeConfigMap extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeConfigMapProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeConfigMapProps = {} + ) { super(scope, id, { ...KubeConfigMap.GVK, ...props, @@ -3046,9 +3274,9 @@ export class KubeConfigMapList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ConfigMapList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ConfigMapList', - } + apiVersion: "v1", + kind: "ConfigMapList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ConfigMapList". @@ -3070,7 +3298,11 @@ export class KubeConfigMapList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeConfigMapListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeConfigMapListProps + ) { super(scope, id, { ...KubeConfigMapList.GVK, ...props, @@ -3111,9 +3343,9 @@ export class KubeEndpoints extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.Endpoints" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'Endpoints', - } + apiVersion: "v1", + kind: "Endpoints", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.Endpoints". @@ -3135,7 +3367,11 @@ export class KubeEndpoints extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEndpointsProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeEndpointsProps = {} + ) { super(scope, id, { ...KubeEndpoints.GVK, ...props, @@ -3165,9 +3401,9 @@ export class KubeEndpointsList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.EndpointsList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'EndpointsList', - } + apiVersion: "v1", + kind: "EndpointsList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.EndpointsList". @@ -3189,7 +3425,11 @@ export class KubeEndpointsList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEndpointsListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeEndpointsListProps + ) { super(scope, id, { ...KubeEndpointsList.GVK, ...props, @@ -3219,9 +3459,9 @@ export class KubeEphemeralContainers extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.EphemeralContainers" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'EphemeralContainers', - } + apiVersion: "v1", + kind: "EphemeralContainers", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.EphemeralContainers". @@ -3243,7 +3483,11 @@ export class KubeEphemeralContainers extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEphemeralContainersProps) { + public constructor( + scope: Construct, + id: string, + props: KubeEphemeralContainersProps + ) { super(scope, id, { ...KubeEphemeralContainers.GVK, ...props, @@ -3273,9 +3517,9 @@ export class KubeEvent extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.events.v1.Event" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'events.k8s.io/v1', - kind: 'Event', - } + apiVersion: "events.k8s.io/v1", + kind: "Event", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.events.v1.Event". @@ -3327,9 +3571,9 @@ export class KubeEventList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.events.v1.EventList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'events.k8s.io/v1', - kind: 'EventList', - } + apiVersion: "events.k8s.io/v1", + kind: "EventList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.events.v1.EventList". @@ -3381,9 +3625,9 @@ export class KubeLimitRange extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.LimitRange" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'LimitRange', - } + apiVersion: "v1", + kind: "LimitRange", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.LimitRange". @@ -3405,7 +3649,11 @@ export class KubeLimitRange extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeLimitRangeProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeLimitRangeProps = {} + ) { super(scope, id, { ...KubeLimitRange.GVK, ...props, @@ -3435,9 +3683,9 @@ export class KubeLimitRangeList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.LimitRangeList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'LimitRangeList', - } + apiVersion: "v1", + kind: "LimitRangeList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.LimitRangeList". @@ -3459,7 +3707,11 @@ export class KubeLimitRangeList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeLimitRangeListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeLimitRangeListProps + ) { super(scope, id, { ...KubeLimitRangeList.GVK, ...props, @@ -3489,9 +3741,9 @@ export class KubeNamespace extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.Namespace" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'Namespace', - } + apiVersion: "v1", + kind: "Namespace", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.Namespace". @@ -3513,7 +3765,11 @@ export class KubeNamespace extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeNamespaceProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeNamespaceProps = {} + ) { super(scope, id, { ...KubeNamespace.GVK, ...props, @@ -3543,9 +3799,9 @@ export class KubeNamespaceList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.NamespaceList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'NamespaceList', - } + apiVersion: "v1", + kind: "NamespaceList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.NamespaceList". @@ -3567,7 +3823,11 @@ export class KubeNamespaceList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeNamespaceListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeNamespaceListProps + ) { super(scope, id, { ...KubeNamespaceList.GVK, ...props, @@ -3597,9 +3857,9 @@ export class KubeNode extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.Node" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'Node', - } + apiVersion: "v1", + kind: "Node", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.Node". @@ -3651,9 +3911,9 @@ export class KubeNodeList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.NodeList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'NodeList', - } + apiVersion: "v1", + kind: "NodeList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.NodeList". @@ -3705,9 +3965,9 @@ export class KubePersistentVolume extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.PersistentVolume" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'PersistentVolume', - } + apiVersion: "v1", + kind: "PersistentVolume", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.PersistentVolume". @@ -3729,7 +3989,11 @@ export class KubePersistentVolume extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePersistentVolumeProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubePersistentVolumeProps = {} + ) { super(scope, id, { ...KubePersistentVolume.GVK, ...props, @@ -3759,9 +4023,9 @@ export class KubePersistentVolumeClaim extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.PersistentVolumeClaim" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'PersistentVolumeClaim', - } + apiVersion: "v1", + kind: "PersistentVolumeClaim", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.PersistentVolumeClaim". @@ -3783,7 +4047,11 @@ export class KubePersistentVolumeClaim extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePersistentVolumeClaimProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubePersistentVolumeClaimProps = {} + ) { super(scope, id, { ...KubePersistentVolumeClaim.GVK, ...props, @@ -3813,9 +4081,9 @@ export class KubePersistentVolumeClaimList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.PersistentVolumeClaimList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'PersistentVolumeClaimList', - } + apiVersion: "v1", + kind: "PersistentVolumeClaimList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.PersistentVolumeClaimList". @@ -3837,7 +4105,11 @@ export class KubePersistentVolumeClaimList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePersistentVolumeClaimListProps) { + public constructor( + scope: Construct, + id: string, + props: KubePersistentVolumeClaimListProps + ) { super(scope, id, { ...KubePersistentVolumeClaimList.GVK, ...props, @@ -3867,9 +4139,9 @@ export class KubePersistentVolumeList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.PersistentVolumeList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'PersistentVolumeList', - } + apiVersion: "v1", + kind: "PersistentVolumeList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.PersistentVolumeList". @@ -3891,7 +4163,11 @@ export class KubePersistentVolumeList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePersistentVolumeListProps) { + public constructor( + scope: Construct, + id: string, + props: KubePersistentVolumeListProps + ) { super(scope, id, { ...KubePersistentVolumeList.GVK, ...props, @@ -3921,9 +4197,9 @@ export class KubePod extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.Pod" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'Pod', - } + apiVersion: "v1", + kind: "Pod", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.Pod". @@ -3975,9 +4251,9 @@ export class KubePodList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.PodList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'PodList', - } + apiVersion: "v1", + kind: "PodList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.PodList". @@ -4029,9 +4305,9 @@ export class KubePodTemplate extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.PodTemplate" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'PodTemplate', - } + apiVersion: "v1", + kind: "PodTemplate", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.PodTemplate". @@ -4053,7 +4329,11 @@ export class KubePodTemplate extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePodTemplateProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubePodTemplateProps = {} + ) { super(scope, id, { ...KubePodTemplate.GVK, ...props, @@ -4083,9 +4363,9 @@ export class KubePodTemplateList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.PodTemplateList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'PodTemplateList', - } + apiVersion: "v1", + kind: "PodTemplateList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.PodTemplateList". @@ -4107,7 +4387,11 @@ export class KubePodTemplateList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePodTemplateListProps) { + public constructor( + scope: Construct, + id: string, + props: KubePodTemplateListProps + ) { super(scope, id, { ...KubePodTemplateList.GVK, ...props, @@ -4137,9 +4421,9 @@ export class KubeReplicationController extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ReplicationController" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ReplicationController', - } + apiVersion: "v1", + kind: "ReplicationController", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ReplicationController". @@ -4161,7 +4445,11 @@ export class KubeReplicationController extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeReplicationControllerProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeReplicationControllerProps = {} + ) { super(scope, id, { ...KubeReplicationController.GVK, ...props, @@ -4191,9 +4479,9 @@ export class KubeReplicationControllerList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ReplicationControllerList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ReplicationControllerList', - } + apiVersion: "v1", + kind: "ReplicationControllerList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ReplicationControllerList". @@ -4215,7 +4503,11 @@ export class KubeReplicationControllerList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeReplicationControllerListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeReplicationControllerListProps + ) { super(scope, id, { ...KubeReplicationControllerList.GVK, ...props, @@ -4245,9 +4537,9 @@ export class KubeResourceQuota extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ResourceQuota" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ResourceQuota', - } + apiVersion: "v1", + kind: "ResourceQuota", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ResourceQuota". @@ -4269,7 +4561,11 @@ export class KubeResourceQuota extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeResourceQuotaProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeResourceQuotaProps = {} + ) { super(scope, id, { ...KubeResourceQuota.GVK, ...props, @@ -4299,9 +4595,9 @@ export class KubeResourceQuotaList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ResourceQuotaList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ResourceQuotaList', - } + apiVersion: "v1", + kind: "ResourceQuotaList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ResourceQuotaList". @@ -4323,7 +4619,11 @@ export class KubeResourceQuotaList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeResourceQuotaListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeResourceQuotaListProps + ) { super(scope, id, { ...KubeResourceQuotaList.GVK, ...props, @@ -4353,9 +4653,9 @@ export class KubeSecret extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.Secret" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'Secret', - } + apiVersion: "v1", + kind: "Secret", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.Secret". @@ -4377,7 +4677,11 @@ export class KubeSecret extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeSecretProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeSecretProps = {} + ) { super(scope, id, { ...KubeSecret.GVK, ...props, @@ -4407,9 +4711,9 @@ export class KubeSecretList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.SecretList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'SecretList', - } + apiVersion: "v1", + kind: "SecretList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.SecretList". @@ -4461,9 +4765,9 @@ export class KubeService extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.Service" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'Service', - } + apiVersion: "v1", + kind: "Service", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.Service". @@ -4485,7 +4789,11 @@ export class KubeService extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeServiceProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeServiceProps = {} + ) { super(scope, id, { ...KubeService.GVK, ...props, @@ -4515,9 +4823,9 @@ export class KubeServiceAccount extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ServiceAccount" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ServiceAccount', - } + apiVersion: "v1", + kind: "ServiceAccount", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ServiceAccount". @@ -4539,7 +4847,11 @@ export class KubeServiceAccount extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeServiceAccountProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeServiceAccountProps = {} + ) { super(scope, id, { ...KubeServiceAccount.GVK, ...props, @@ -4569,9 +4881,9 @@ export class KubeServiceAccountList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ServiceAccountList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ServiceAccountList', - } + apiVersion: "v1", + kind: "ServiceAccountList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ServiceAccountList". @@ -4593,7 +4905,11 @@ export class KubeServiceAccountList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeServiceAccountListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeServiceAccountListProps + ) { super(scope, id, { ...KubeServiceAccountList.GVK, ...props, @@ -4623,9 +4939,9 @@ export class KubeServiceList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.core.v1.ServiceList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'ServiceList', - } + apiVersion: "v1", + kind: "ServiceList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.core.v1.ServiceList". @@ -4647,7 +4963,11 @@ export class KubeServiceList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeServiceListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeServiceListProps + ) { super(scope, id, { ...KubeServiceList.GVK, ...props, @@ -4677,9 +4997,9 @@ export class KubeEndpointSlice extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.discovery.v1.EndpointSlice" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'discovery.k8s.io/v1', - kind: 'EndpointSlice', - } + apiVersion: "discovery.k8s.io/v1", + kind: "EndpointSlice", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.discovery.v1.EndpointSlice". @@ -4701,7 +5021,11 @@ export class KubeEndpointSlice extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEndpointSliceProps) { + public constructor( + scope: Construct, + id: string, + props: KubeEndpointSliceProps + ) { super(scope, id, { ...KubeEndpointSlice.GVK, ...props, @@ -4731,9 +5055,9 @@ export class KubeEndpointSliceList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.discovery.v1.EndpointSliceList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'discovery.k8s.io/v1', - kind: 'EndpointSliceList', - } + apiVersion: "discovery.k8s.io/v1", + kind: "EndpointSliceList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.discovery.v1.EndpointSliceList". @@ -4755,7 +5079,11 @@ export class KubeEndpointSliceList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEndpointSliceListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeEndpointSliceListProps + ) { super(scope, id, { ...KubeEndpointSliceList.GVK, ...props, @@ -4785,9 +5113,9 @@ export class KubeEndpointSliceV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.discovery.v1beta1.EndpointSlice" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'discovery.k8s.io/v1beta1', - kind: 'EndpointSlice', - } + apiVersion: "discovery.k8s.io/v1beta1", + kind: "EndpointSlice", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.discovery.v1beta1.EndpointSlice". @@ -4809,7 +5137,11 @@ export class KubeEndpointSliceV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEndpointSliceV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeEndpointSliceV1Beta1Props + ) { super(scope, id, { ...KubeEndpointSliceV1Beta1.GVK, ...props, @@ -4839,9 +5171,9 @@ export class KubeEndpointSliceListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.discovery.v1beta1.EndpointSliceList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'discovery.k8s.io/v1beta1', - kind: 'EndpointSliceList', - } + apiVersion: "discovery.k8s.io/v1beta1", + kind: "EndpointSliceList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.discovery.v1beta1.EndpointSliceList". @@ -4863,7 +5195,11 @@ export class KubeEndpointSliceListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEndpointSliceListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeEndpointSliceListV1Beta1Props + ) { super(scope, id, { ...KubeEndpointSliceListV1Beta1.GVK, ...props, @@ -4893,9 +5229,9 @@ export class KubeEventV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.events.v1beta1.Event" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'events.k8s.io/v1beta1', - kind: 'Event', - } + apiVersion: "events.k8s.io/v1beta1", + kind: "Event", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.events.v1beta1.Event". @@ -4917,7 +5253,11 @@ export class KubeEventV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEventV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeEventV1Beta1Props + ) { super(scope, id, { ...KubeEventV1Beta1.GVK, ...props, @@ -4947,9 +5287,9 @@ export class KubeEventListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.events.v1beta1.EventList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'events.k8s.io/v1beta1', - kind: 'EventList', - } + apiVersion: "events.k8s.io/v1beta1", + kind: "EventList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.events.v1beta1.EventList". @@ -4971,7 +5311,11 @@ export class KubeEventListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEventListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeEventListV1Beta1Props + ) { super(scope, id, { ...KubeEventListV1Beta1.GVK, ...props, @@ -5001,9 +5345,9 @@ export class KubeIngressV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1beta1.Ingress" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'Ingress', - } + apiVersion: "networking.k8s.io/v1", + kind: "Ingress", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1beta1.Ingress". @@ -5025,7 +5369,11 @@ export class KubeIngressV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeIngressV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeIngressV1Beta1Props = {} + ) { super(scope, id, { ...KubeIngressV1Beta1.GVK, ...props, @@ -5055,9 +5403,9 @@ export class KubeIngressListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1beta1.IngressList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'IngressList', - } + apiVersion: "networking.k8s.io/v1", + kind: "IngressList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1beta1.IngressList". @@ -5079,7 +5427,11 @@ export class KubeIngressListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeIngressListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeIngressListV1Beta1Props + ) { super(scope, id, { ...KubeIngressListV1Beta1.GVK, ...props, @@ -5109,9 +5461,9 @@ export class KubeFlowSchemaV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.flowcontrol.v1beta1.FlowSchema" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'flowcontrol.apiserver.k8s.io/v1beta1', - kind: 'FlowSchema', - } + apiVersion: "flowcontrol.apiserver.k8s.io/v1beta1", + kind: "FlowSchema", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.flowcontrol.v1beta1.FlowSchema". @@ -5133,7 +5485,11 @@ export class KubeFlowSchemaV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeFlowSchemaV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeFlowSchemaV1Beta1Props = {} + ) { super(scope, id, { ...KubeFlowSchemaV1Beta1.GVK, ...props, @@ -5163,9 +5519,9 @@ export class KubeFlowSchemaListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.flowcontrol.v1beta1.FlowSchemaList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'flowcontrol.apiserver.k8s.io/v1beta1', - kind: 'FlowSchemaList', - } + apiVersion: "flowcontrol.apiserver.k8s.io/v1beta1", + kind: "FlowSchemaList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.flowcontrol.v1beta1.FlowSchemaList". @@ -5187,7 +5543,11 @@ export class KubeFlowSchemaListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeFlowSchemaListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeFlowSchemaListV1Beta1Props + ) { super(scope, id, { ...KubeFlowSchemaListV1Beta1.GVK, ...props, @@ -5217,9 +5577,9 @@ export class KubePriorityLevelConfigurationV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.flowcontrol.v1beta1.PriorityLevelConfiguration" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'flowcontrol.apiserver.k8s.io/v1beta1', - kind: 'PriorityLevelConfiguration', - } + apiVersion: "flowcontrol.apiserver.k8s.io/v1beta1", + kind: "PriorityLevelConfiguration", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.flowcontrol.v1beta1.PriorityLevelConfiguration". @@ -5228,7 +5588,9 @@ export class KubePriorityLevelConfigurationV1Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubePriorityLevelConfigurationV1Beta1Props = {}): any { + public static manifest( + props: KubePriorityLevelConfigurationV1Beta1Props = {} + ): any { return { ...KubePriorityLevelConfigurationV1Beta1.GVK, ...toJson_KubePriorityLevelConfigurationV1Beta1Props(props), @@ -5241,7 +5603,11 @@ export class KubePriorityLevelConfigurationV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePriorityLevelConfigurationV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubePriorityLevelConfigurationV1Beta1Props = {} + ) { super(scope, id, { ...KubePriorityLevelConfigurationV1Beta1.GVK, ...props, @@ -5271,9 +5637,9 @@ export class KubePriorityLevelConfigurationListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.flowcontrol.v1beta1.PriorityLevelConfigurationList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'flowcontrol.apiserver.k8s.io/v1beta1', - kind: 'PriorityLevelConfigurationList', - } + apiVersion: "flowcontrol.apiserver.k8s.io/v1beta1", + kind: "PriorityLevelConfigurationList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.flowcontrol.v1beta1.PriorityLevelConfigurationList". @@ -5282,7 +5648,9 @@ export class KubePriorityLevelConfigurationListV1Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubePriorityLevelConfigurationListV1Beta1Props): any { + public static manifest( + props: KubePriorityLevelConfigurationListV1Beta1Props + ): any { return { ...KubePriorityLevelConfigurationListV1Beta1.GVK, ...toJson_KubePriorityLevelConfigurationListV1Beta1Props(props), @@ -5295,7 +5663,11 @@ export class KubePriorityLevelConfigurationListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePriorityLevelConfigurationListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubePriorityLevelConfigurationListV1Beta1Props + ) { super(scope, id, { ...KubePriorityLevelConfigurationListV1Beta1.GVK, ...props, @@ -5325,9 +5697,9 @@ export class KubeIngress extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1.Ingress" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'Ingress', - } + apiVersion: "networking.k8s.io/v1", + kind: "Ingress", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1.Ingress". @@ -5349,7 +5721,11 @@ export class KubeIngress extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeIngressProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeIngressProps = {} + ) { super(scope, id, { ...KubeIngress.GVK, ...props, @@ -5379,9 +5755,9 @@ export class KubeIngressClass extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1.IngressClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'IngressClass', - } + apiVersion: "networking.k8s.io/v1", + kind: "IngressClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1.IngressClass". @@ -5403,7 +5779,11 @@ export class KubeIngressClass extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeIngressClassProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeIngressClassProps = {} + ) { super(scope, id, { ...KubeIngressClass.GVK, ...props, @@ -5433,9 +5813,9 @@ export class KubeIngressClassList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1.IngressClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'IngressClassList', - } + apiVersion: "networking.k8s.io/v1", + kind: "IngressClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1.IngressClassList". @@ -5457,7 +5837,11 @@ export class KubeIngressClassList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeIngressClassListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeIngressClassListProps + ) { super(scope, id, { ...KubeIngressClassList.GVK, ...props, @@ -5487,9 +5871,9 @@ export class KubeIngressList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1.IngressList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'IngressList', - } + apiVersion: "networking.k8s.io/v1", + kind: "IngressList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1.IngressList". @@ -5511,7 +5895,11 @@ export class KubeIngressList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeIngressListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeIngressListProps + ) { super(scope, id, { ...KubeIngressList.GVK, ...props, @@ -5541,9 +5929,9 @@ export class KubeNetworkPolicy extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1.NetworkPolicy" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'NetworkPolicy', - } + apiVersion: "networking.k8s.io/v1", + kind: "NetworkPolicy", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1.NetworkPolicy". @@ -5565,7 +5953,11 @@ export class KubeNetworkPolicy extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeNetworkPolicyProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeNetworkPolicyProps = {} + ) { super(scope, id, { ...KubeNetworkPolicy.GVK, ...props, @@ -5595,9 +5987,9 @@ export class KubeNetworkPolicyList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1.NetworkPolicyList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'NetworkPolicyList', - } + apiVersion: "networking.k8s.io/v1", + kind: "NetworkPolicyList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1.NetworkPolicyList". @@ -5619,7 +6011,11 @@ export class KubeNetworkPolicyList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeNetworkPolicyListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeNetworkPolicyListProps + ) { super(scope, id, { ...KubeNetworkPolicyList.GVK, ...props, @@ -5649,9 +6045,9 @@ export class KubeIngressClassV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1beta1.IngressClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'IngressClass', - } + apiVersion: "networking.k8s.io/v1", + kind: "IngressClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1beta1.IngressClass". @@ -5673,7 +6069,11 @@ export class KubeIngressClassV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeIngressClassV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeIngressClassV1Beta1Props = {} + ) { super(scope, id, { ...KubeIngressClassV1Beta1.GVK, ...props, @@ -5703,9 +6103,9 @@ export class KubeIngressClassListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.networking.v1beta1.IngressClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'networking.k8s.io/v1', - kind: 'IngressClassList', - } + apiVersion: "networking.k8s.io/v1", + kind: "IngressClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.networking.v1beta1.IngressClassList". @@ -5727,7 +6127,11 @@ export class KubeIngressClassListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeIngressClassListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeIngressClassListV1Beta1Props + ) { super(scope, id, { ...KubeIngressClassListV1Beta1.GVK, ...props, @@ -5757,9 +6161,9 @@ export class KubeRuntimeClass extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.node.v1.RuntimeClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'node.k8s.io/v1', - kind: 'RuntimeClass', - } + apiVersion: "node.k8s.io/v1", + kind: "RuntimeClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.node.v1.RuntimeClass". @@ -5781,7 +6185,11 @@ export class KubeRuntimeClass extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRuntimeClassProps) { + public constructor( + scope: Construct, + id: string, + props: KubeRuntimeClassProps + ) { super(scope, id, { ...KubeRuntimeClass.GVK, ...props, @@ -5811,9 +6219,9 @@ export class KubeRuntimeClassList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.node.v1.RuntimeClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'node.k8s.io/v1', - kind: 'RuntimeClassList', - } + apiVersion: "node.k8s.io/v1", + kind: "RuntimeClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.node.v1.RuntimeClassList". @@ -5835,7 +6243,11 @@ export class KubeRuntimeClassList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRuntimeClassListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeRuntimeClassListProps + ) { super(scope, id, { ...KubeRuntimeClassList.GVK, ...props, @@ -5865,9 +6277,9 @@ export class KubeRuntimeClassV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.node.v1alpha1.RuntimeClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'node.k8s.io/v1alpha1', - kind: 'RuntimeClass', - } + apiVersion: "node.k8s.io/v1alpha1", + kind: "RuntimeClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.node.v1alpha1.RuntimeClass". @@ -5889,7 +6301,11 @@ export class KubeRuntimeClassV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRuntimeClassV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRuntimeClassV1Alpha1Props + ) { super(scope, id, { ...KubeRuntimeClassV1Alpha1.GVK, ...props, @@ -5919,9 +6335,9 @@ export class KubeRuntimeClassListV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.node.v1alpha1.RuntimeClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'node.k8s.io/v1alpha1', - kind: 'RuntimeClassList', - } + apiVersion: "node.k8s.io/v1alpha1", + kind: "RuntimeClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.node.v1alpha1.RuntimeClassList". @@ -5943,7 +6359,11 @@ export class KubeRuntimeClassListV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRuntimeClassListV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRuntimeClassListV1Alpha1Props + ) { super(scope, id, { ...KubeRuntimeClassListV1Alpha1.GVK, ...props, @@ -5973,9 +6393,9 @@ export class KubeRuntimeClassV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.node.v1beta1.RuntimeClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'node.k8s.io/v1beta1', - kind: 'RuntimeClass', - } + apiVersion: "node.k8s.io/v1beta1", + kind: "RuntimeClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.node.v1beta1.RuntimeClass". @@ -5997,7 +6417,11 @@ export class KubeRuntimeClassV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRuntimeClassV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRuntimeClassV1Beta1Props + ) { super(scope, id, { ...KubeRuntimeClassV1Beta1.GVK, ...props, @@ -6027,9 +6451,9 @@ export class KubeRuntimeClassListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.node.v1beta1.RuntimeClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'node.k8s.io/v1beta1', - kind: 'RuntimeClassList', - } + apiVersion: "node.k8s.io/v1beta1", + kind: "RuntimeClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.node.v1beta1.RuntimeClassList". @@ -6051,7 +6475,11 @@ export class KubeRuntimeClassListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRuntimeClassListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRuntimeClassListV1Beta1Props + ) { super(scope, id, { ...KubeRuntimeClassListV1Beta1.GVK, ...props, @@ -6081,9 +6509,9 @@ export class KubePodDisruptionBudget extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.policy.v1.PodDisruptionBudget" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'policy/v1', - kind: 'PodDisruptionBudget', - } + apiVersion: "policy/v1", + kind: "PodDisruptionBudget", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.policy.v1.PodDisruptionBudget". @@ -6105,7 +6533,11 @@ export class KubePodDisruptionBudget extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePodDisruptionBudgetProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubePodDisruptionBudgetProps = {} + ) { super(scope, id, { ...KubePodDisruptionBudget.GVK, ...props, @@ -6135,9 +6567,9 @@ export class KubePodDisruptionBudgetList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.policy.v1.PodDisruptionBudgetList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'policy/v1', - kind: 'PodDisruptionBudgetList', - } + apiVersion: "policy/v1", + kind: "PodDisruptionBudgetList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.policy.v1.PodDisruptionBudgetList". @@ -6159,7 +6591,11 @@ export class KubePodDisruptionBudgetList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePodDisruptionBudgetListProps) { + public constructor( + scope: Construct, + id: string, + props: KubePodDisruptionBudgetListProps + ) { super(scope, id, { ...KubePodDisruptionBudgetList.GVK, ...props, @@ -6189,9 +6625,9 @@ export class KubeEvictionV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.policy.v1beta1.Eviction" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'policy/v1beta1', - kind: 'Eviction', - } + apiVersion: "policy/v1beta1", + kind: "Eviction", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.policy.v1beta1.Eviction". @@ -6213,7 +6649,11 @@ export class KubeEvictionV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeEvictionV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeEvictionV1Beta1Props = {} + ) { super(scope, id, { ...KubeEvictionV1Beta1.GVK, ...props, @@ -6243,9 +6683,9 @@ export class KubePodDisruptionBudgetV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.policy.v1beta1.PodDisruptionBudget" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'policy/v1beta1', - kind: 'PodDisruptionBudget', - } + apiVersion: "policy/v1beta1", + kind: "PodDisruptionBudget", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.policy.v1beta1.PodDisruptionBudget". @@ -6267,7 +6707,11 @@ export class KubePodDisruptionBudgetV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePodDisruptionBudgetV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubePodDisruptionBudgetV1Beta1Props = {} + ) { super(scope, id, { ...KubePodDisruptionBudgetV1Beta1.GVK, ...props, @@ -6297,9 +6741,9 @@ export class KubePodDisruptionBudgetListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.policy.v1beta1.PodDisruptionBudgetList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'policy/v1beta1', - kind: 'PodDisruptionBudgetList', - } + apiVersion: "policy/v1beta1", + kind: "PodDisruptionBudgetList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.policy.v1beta1.PodDisruptionBudgetList". @@ -6321,7 +6765,11 @@ export class KubePodDisruptionBudgetListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePodDisruptionBudgetListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubePodDisruptionBudgetListV1Beta1Props + ) { super(scope, id, { ...KubePodDisruptionBudgetListV1Beta1.GVK, ...props, @@ -6351,9 +6799,9 @@ export class KubePodSecurityPolicyV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.policy.v1beta1.PodSecurityPolicy" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'policy/v1beta1', - kind: 'PodSecurityPolicy', - } + apiVersion: "policy/v1beta1", + kind: "PodSecurityPolicy", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.policy.v1beta1.PodSecurityPolicy". @@ -6375,7 +6823,11 @@ export class KubePodSecurityPolicyV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePodSecurityPolicyV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubePodSecurityPolicyV1Beta1Props = {} + ) { super(scope, id, { ...KubePodSecurityPolicyV1Beta1.GVK, ...props, @@ -6405,9 +6857,9 @@ export class KubePodSecurityPolicyListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.policy.v1beta1.PodSecurityPolicyList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'policy/v1beta1', - kind: 'PodSecurityPolicyList', - } + apiVersion: "policy/v1beta1", + kind: "PodSecurityPolicyList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.policy.v1beta1.PodSecurityPolicyList". @@ -6429,7 +6881,11 @@ export class KubePodSecurityPolicyListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePodSecurityPolicyListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubePodSecurityPolicyListV1Beta1Props + ) { super(scope, id, { ...KubePodSecurityPolicyListV1Beta1.GVK, ...props, @@ -6459,9 +6915,9 @@ export class KubeClusterRole extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1.ClusterRole" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'ClusterRole', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "ClusterRole", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1.ClusterRole". @@ -6483,7 +6939,11 @@ export class KubeClusterRole extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleProps = {} + ) { super(scope, id, { ...KubeClusterRole.GVK, ...props, @@ -6513,9 +6973,9 @@ export class KubeClusterRoleBinding extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1.ClusterRoleBinding" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'ClusterRoleBinding', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "ClusterRoleBinding", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1.ClusterRoleBinding". @@ -6537,7 +6997,11 @@ export class KubeClusterRoleBinding extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleBindingProps) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleBindingProps + ) { super(scope, id, { ...KubeClusterRoleBinding.GVK, ...props, @@ -6567,9 +7031,9 @@ export class KubeClusterRoleBindingList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1.ClusterRoleBindingList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'ClusterRoleBindingList', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "ClusterRoleBindingList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1.ClusterRoleBindingList". @@ -6591,7 +7055,11 @@ export class KubeClusterRoleBindingList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleBindingListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleBindingListProps + ) { super(scope, id, { ...KubeClusterRoleBindingList.GVK, ...props, @@ -6621,9 +7089,9 @@ export class KubeClusterRoleList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1.ClusterRoleList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'ClusterRoleList', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "ClusterRoleList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1.ClusterRoleList". @@ -6645,7 +7113,11 @@ export class KubeClusterRoleList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleListProps + ) { super(scope, id, { ...KubeClusterRoleList.GVK, ...props, @@ -6675,9 +7147,9 @@ export class KubeRole extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1.Role" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'Role', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "Role", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1.Role". @@ -6729,9 +7201,9 @@ export class KubeRoleBinding extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1.RoleBinding" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'RoleBinding', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "RoleBinding", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1.RoleBinding". @@ -6753,7 +7225,11 @@ export class KubeRoleBinding extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleBindingProps) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleBindingProps + ) { super(scope, id, { ...KubeRoleBinding.GVK, ...props, @@ -6783,9 +7259,9 @@ export class KubeRoleBindingList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1.RoleBindingList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'RoleBindingList', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "RoleBindingList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1.RoleBindingList". @@ -6807,7 +7283,11 @@ export class KubeRoleBindingList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleBindingListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleBindingListProps + ) { super(scope, id, { ...KubeRoleBindingList.GVK, ...props, @@ -6837,9 +7317,9 @@ export class KubeRoleList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1.RoleList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'RoleList', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "RoleList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1.RoleList". @@ -6891,9 +7371,9 @@ export class KubeClusterRoleV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1alpha1.ClusterRole" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1alpha1', - kind: 'ClusterRole', - } + apiVersion: "rbac.authorization.k8s.io/v1alpha1", + kind: "ClusterRole", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1alpha1.ClusterRole". @@ -6915,7 +7395,11 @@ export class KubeClusterRoleV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleV1Alpha1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleV1Alpha1Props = {} + ) { super(scope, id, { ...KubeClusterRoleV1Alpha1.GVK, ...props, @@ -6945,9 +7429,9 @@ export class KubeClusterRoleBindingV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1alpha1.ClusterRoleBinding" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1alpha1', - kind: 'ClusterRoleBinding', - } + apiVersion: "rbac.authorization.k8s.io/v1alpha1", + kind: "ClusterRoleBinding", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1alpha1.ClusterRoleBinding". @@ -6969,7 +7453,11 @@ export class KubeClusterRoleBindingV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleBindingV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleBindingV1Alpha1Props + ) { super(scope, id, { ...KubeClusterRoleBindingV1Alpha1.GVK, ...props, @@ -6999,9 +7487,9 @@ export class KubeClusterRoleBindingListV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1alpha1.ClusterRoleBindingList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1alpha1', - kind: 'ClusterRoleBindingList', - } + apiVersion: "rbac.authorization.k8s.io/v1alpha1", + kind: "ClusterRoleBindingList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1alpha1.ClusterRoleBindingList". @@ -7023,7 +7511,11 @@ export class KubeClusterRoleBindingListV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleBindingListV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleBindingListV1Alpha1Props + ) { super(scope, id, { ...KubeClusterRoleBindingListV1Alpha1.GVK, ...props, @@ -7053,9 +7545,9 @@ export class KubeClusterRoleListV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1alpha1.ClusterRoleList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1alpha1', - kind: 'ClusterRoleList', - } + apiVersion: "rbac.authorization.k8s.io/v1alpha1", + kind: "ClusterRoleList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1alpha1.ClusterRoleList". @@ -7077,7 +7569,11 @@ export class KubeClusterRoleListV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleListV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleListV1Alpha1Props + ) { super(scope, id, { ...KubeClusterRoleListV1Alpha1.GVK, ...props, @@ -7107,9 +7603,9 @@ export class KubeRoleV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1alpha1.Role" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1alpha1', - kind: 'Role', - } + apiVersion: "rbac.authorization.k8s.io/v1alpha1", + kind: "Role", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1alpha1.Role". @@ -7131,7 +7627,11 @@ export class KubeRoleV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleV1Alpha1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleV1Alpha1Props = {} + ) { super(scope, id, { ...KubeRoleV1Alpha1.GVK, ...props, @@ -7161,9 +7661,9 @@ export class KubeRoleBindingV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1alpha1.RoleBinding" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1alpha1', - kind: 'RoleBinding', - } + apiVersion: "rbac.authorization.k8s.io/v1alpha1", + kind: "RoleBinding", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1alpha1.RoleBinding". @@ -7185,7 +7685,11 @@ export class KubeRoleBindingV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleBindingV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleBindingV1Alpha1Props + ) { super(scope, id, { ...KubeRoleBindingV1Alpha1.GVK, ...props, @@ -7215,9 +7719,9 @@ export class KubeRoleBindingListV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1alpha1.RoleBindingList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1alpha1', - kind: 'RoleBindingList', - } + apiVersion: "rbac.authorization.k8s.io/v1alpha1", + kind: "RoleBindingList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1alpha1.RoleBindingList". @@ -7239,7 +7743,11 @@ export class KubeRoleBindingListV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleBindingListV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleBindingListV1Alpha1Props + ) { super(scope, id, { ...KubeRoleBindingListV1Alpha1.GVK, ...props, @@ -7269,9 +7777,9 @@ export class KubeRoleListV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1alpha1.RoleList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1alpha1', - kind: 'RoleList', - } + apiVersion: "rbac.authorization.k8s.io/v1alpha1", + kind: "RoleList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1alpha1.RoleList". @@ -7293,7 +7801,11 @@ export class KubeRoleListV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleListV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleListV1Alpha1Props + ) { super(scope, id, { ...KubeRoleListV1Alpha1.GVK, ...props, @@ -7323,9 +7835,9 @@ export class KubeClusterRoleV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1beta1.ClusterRole" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'ClusterRole', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "ClusterRole", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1beta1.ClusterRole". @@ -7347,7 +7859,11 @@ export class KubeClusterRoleV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleV1Beta1Props = {} + ) { super(scope, id, { ...KubeClusterRoleV1Beta1.GVK, ...props, @@ -7377,9 +7893,9 @@ export class KubeClusterRoleBindingV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1beta1.ClusterRoleBinding" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'ClusterRoleBinding', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "ClusterRoleBinding", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1beta1.ClusterRoleBinding". @@ -7401,7 +7917,11 @@ export class KubeClusterRoleBindingV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleBindingV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleBindingV1Beta1Props + ) { super(scope, id, { ...KubeClusterRoleBindingV1Beta1.GVK, ...props, @@ -7431,9 +7951,9 @@ export class KubeClusterRoleBindingListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1beta1.ClusterRoleBindingList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'ClusterRoleBindingList', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "ClusterRoleBindingList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1beta1.ClusterRoleBindingList". @@ -7455,7 +7975,11 @@ export class KubeClusterRoleBindingListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleBindingListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleBindingListV1Beta1Props + ) { super(scope, id, { ...KubeClusterRoleBindingListV1Beta1.GVK, ...props, @@ -7485,9 +8009,9 @@ export class KubeClusterRoleListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1beta1.ClusterRoleList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'ClusterRoleList', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "ClusterRoleList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1beta1.ClusterRoleList". @@ -7509,7 +8033,11 @@ export class KubeClusterRoleListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeClusterRoleListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeClusterRoleListV1Beta1Props + ) { super(scope, id, { ...KubeClusterRoleListV1Beta1.GVK, ...props, @@ -7539,9 +8067,9 @@ export class KubeRoleV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1beta1.Role" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'Role', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "Role", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1beta1.Role". @@ -7563,7 +8091,11 @@ export class KubeRoleV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleV1Beta1Props = {} + ) { super(scope, id, { ...KubeRoleV1Beta1.GVK, ...props, @@ -7593,9 +8125,9 @@ export class KubeRoleBindingV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1beta1.RoleBinding" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'RoleBinding', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "RoleBinding", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1beta1.RoleBinding". @@ -7617,7 +8149,11 @@ export class KubeRoleBindingV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleBindingV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleBindingV1Beta1Props + ) { super(scope, id, { ...KubeRoleBindingV1Beta1.GVK, ...props, @@ -7647,9 +8183,9 @@ export class KubeRoleBindingListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1beta1.RoleBindingList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'RoleBindingList', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "RoleBindingList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1beta1.RoleBindingList". @@ -7671,7 +8207,11 @@ export class KubeRoleBindingListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleBindingListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleBindingListV1Beta1Props + ) { super(scope, id, { ...KubeRoleBindingListV1Beta1.GVK, ...props, @@ -7701,9 +8241,9 @@ export class KubeRoleListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.rbac.v1beta1.RoleList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'rbac.authorization.k8s.io/v1', - kind: 'RoleList', - } + apiVersion: "rbac.authorization.k8s.io/v1", + kind: "RoleList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.rbac.v1beta1.RoleList". @@ -7725,7 +8265,11 @@ export class KubeRoleListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeRoleListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeRoleListV1Beta1Props + ) { super(scope, id, { ...KubeRoleListV1Beta1.GVK, ...props, @@ -7755,9 +8299,9 @@ export class KubePriorityClass extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.scheduling.v1.PriorityClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'scheduling.k8s.io/v1', - kind: 'PriorityClass', - } + apiVersion: "scheduling.k8s.io/v1", + kind: "PriorityClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.scheduling.v1.PriorityClass". @@ -7779,7 +8323,11 @@ export class KubePriorityClass extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePriorityClassProps) { + public constructor( + scope: Construct, + id: string, + props: KubePriorityClassProps + ) { super(scope, id, { ...KubePriorityClass.GVK, ...props, @@ -7809,9 +8357,9 @@ export class KubePriorityClassList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.scheduling.v1.PriorityClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'scheduling.k8s.io/v1', - kind: 'PriorityClassList', - } + apiVersion: "scheduling.k8s.io/v1", + kind: "PriorityClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.scheduling.v1.PriorityClassList". @@ -7833,7 +8381,11 @@ export class KubePriorityClassList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePriorityClassListProps) { + public constructor( + scope: Construct, + id: string, + props: KubePriorityClassListProps + ) { super(scope, id, { ...KubePriorityClassList.GVK, ...props, @@ -7863,9 +8415,9 @@ export class KubePriorityClassV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.scheduling.v1alpha1.PriorityClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'scheduling.k8s.io/v1alpha1', - kind: 'PriorityClass', - } + apiVersion: "scheduling.k8s.io/v1alpha1", + kind: "PriorityClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.scheduling.v1alpha1.PriorityClass". @@ -7887,7 +8439,11 @@ export class KubePriorityClassV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePriorityClassV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubePriorityClassV1Alpha1Props + ) { super(scope, id, { ...KubePriorityClassV1Alpha1.GVK, ...props, @@ -7917,9 +8473,9 @@ export class KubePriorityClassListV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.scheduling.v1alpha1.PriorityClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'scheduling.k8s.io/v1alpha1', - kind: 'PriorityClassList', - } + apiVersion: "scheduling.k8s.io/v1alpha1", + kind: "PriorityClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.scheduling.v1alpha1.PriorityClassList". @@ -7941,7 +8497,11 @@ export class KubePriorityClassListV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePriorityClassListV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubePriorityClassListV1Alpha1Props + ) { super(scope, id, { ...KubePriorityClassListV1Alpha1.GVK, ...props, @@ -7971,9 +8531,9 @@ export class KubePriorityClassV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.scheduling.v1beta1.PriorityClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'scheduling.k8s.io/v1', - kind: 'PriorityClass', - } + apiVersion: "scheduling.k8s.io/v1", + kind: "PriorityClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.scheduling.v1beta1.PriorityClass". @@ -7995,7 +8555,11 @@ export class KubePriorityClassV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePriorityClassV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubePriorityClassV1Beta1Props + ) { super(scope, id, { ...KubePriorityClassV1Beta1.GVK, ...props, @@ -8025,9 +8589,9 @@ export class KubePriorityClassListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.scheduling.v1beta1.PriorityClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'scheduling.k8s.io/v1', - kind: 'PriorityClassList', - } + apiVersion: "scheduling.k8s.io/v1", + kind: "PriorityClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.scheduling.v1beta1.PriorityClassList". @@ -8049,7 +8613,11 @@ export class KubePriorityClassListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubePriorityClassListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubePriorityClassListV1Beta1Props + ) { super(scope, id, { ...KubePriorityClassListV1Beta1.GVK, ...props, @@ -8079,9 +8647,9 @@ export class KubeCsiDriver extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1.CSIDriver" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSIDriver', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSIDriver", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1.CSIDriver". @@ -8133,9 +8701,9 @@ export class KubeCsiDriverList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1.CSIDriverList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSIDriverList', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSIDriverList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1.CSIDriverList". @@ -8157,7 +8725,11 @@ export class KubeCsiDriverList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiDriverListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiDriverListProps + ) { super(scope, id, { ...KubeCsiDriverList.GVK, ...props, @@ -8187,9 +8759,9 @@ export class KubeCsiNode extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1.CSINode" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSINode', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSINode", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1.CSINode". @@ -8241,9 +8813,9 @@ export class KubeCsiNodeList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1.CSINodeList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSINodeList', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSINodeList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1.CSINodeList". @@ -8265,7 +8837,11 @@ export class KubeCsiNodeList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiNodeListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiNodeListProps + ) { super(scope, id, { ...KubeCsiNodeList.GVK, ...props, @@ -8297,9 +8873,9 @@ export class KubeStorageClass extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1.StorageClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'StorageClass', - } + apiVersion: "storage.k8s.io/v1", + kind: "StorageClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1.StorageClass". @@ -8321,7 +8897,11 @@ export class KubeStorageClass extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeStorageClassProps) { + public constructor( + scope: Construct, + id: string, + props: KubeStorageClassProps + ) { super(scope, id, { ...KubeStorageClass.GVK, ...props, @@ -8351,9 +8931,9 @@ export class KubeStorageClassList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1.StorageClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'StorageClassList', - } + apiVersion: "storage.k8s.io/v1", + kind: "StorageClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1.StorageClassList". @@ -8375,7 +8955,11 @@ export class KubeStorageClassList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeStorageClassListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeStorageClassListProps + ) { super(scope, id, { ...KubeStorageClassList.GVK, ...props, @@ -8407,9 +8991,9 @@ export class KubeVolumeAttachment extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1.VolumeAttachment" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'VolumeAttachment', - } + apiVersion: "storage.k8s.io/v1", + kind: "VolumeAttachment", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1.VolumeAttachment". @@ -8431,7 +9015,11 @@ export class KubeVolumeAttachment extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeVolumeAttachmentProps) { + public constructor( + scope: Construct, + id: string, + props: KubeVolumeAttachmentProps + ) { super(scope, id, { ...KubeVolumeAttachment.GVK, ...props, @@ -8461,9 +9049,9 @@ export class KubeVolumeAttachmentList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1.VolumeAttachmentList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'VolumeAttachmentList', - } + apiVersion: "storage.k8s.io/v1", + kind: "VolumeAttachmentList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1.VolumeAttachmentList". @@ -8485,7 +9073,11 @@ export class KubeVolumeAttachmentList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeVolumeAttachmentListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeVolumeAttachmentListProps + ) { super(scope, id, { ...KubeVolumeAttachmentList.GVK, ...props, @@ -8523,9 +9115,9 @@ export class KubeCsiStorageCapacityV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1alpha1.CSIStorageCapacity" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1alpha1', - kind: 'CSIStorageCapacity', - } + apiVersion: "storage.k8s.io/v1alpha1", + kind: "CSIStorageCapacity", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1alpha1.CSIStorageCapacity". @@ -8547,7 +9139,11 @@ export class KubeCsiStorageCapacityV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiStorageCapacityV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiStorageCapacityV1Alpha1Props + ) { super(scope, id, { ...KubeCsiStorageCapacityV1Alpha1.GVK, ...props, @@ -8577,9 +9173,9 @@ export class KubeCsiStorageCapacityListV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1alpha1.CSIStorageCapacityList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1alpha1', - kind: 'CSIStorageCapacityList', - } + apiVersion: "storage.k8s.io/v1alpha1", + kind: "CSIStorageCapacityList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1alpha1.CSIStorageCapacityList". @@ -8601,7 +9197,11 @@ export class KubeCsiStorageCapacityListV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiStorageCapacityListV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiStorageCapacityListV1Alpha1Props + ) { super(scope, id, { ...KubeCsiStorageCapacityListV1Alpha1.GVK, ...props, @@ -8633,9 +9233,9 @@ export class KubeVolumeAttachmentV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1alpha1.VolumeAttachment" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1alpha1', - kind: 'VolumeAttachment', - } + apiVersion: "storage.k8s.io/v1alpha1", + kind: "VolumeAttachment", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1alpha1.VolumeAttachment". @@ -8657,7 +9257,11 @@ export class KubeVolumeAttachmentV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeVolumeAttachmentV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeVolumeAttachmentV1Alpha1Props + ) { super(scope, id, { ...KubeVolumeAttachmentV1Alpha1.GVK, ...props, @@ -8687,9 +9291,9 @@ export class KubeVolumeAttachmentListV1Alpha1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1alpha1.VolumeAttachmentList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1alpha1', - kind: 'VolumeAttachmentList', - } + apiVersion: "storage.k8s.io/v1alpha1", + kind: "VolumeAttachmentList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1alpha1.VolumeAttachmentList". @@ -8711,7 +9315,11 @@ export class KubeVolumeAttachmentListV1Alpha1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeVolumeAttachmentListV1Alpha1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeVolumeAttachmentListV1Alpha1Props + ) { super(scope, id, { ...KubeVolumeAttachmentListV1Alpha1.GVK, ...props, @@ -8741,9 +9349,9 @@ export class KubeCsiDriverV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.CSIDriver" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSIDriver', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSIDriver", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.CSIDriver". @@ -8765,7 +9373,11 @@ export class KubeCsiDriverV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiDriverV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiDriverV1Beta1Props + ) { super(scope, id, { ...KubeCsiDriverV1Beta1.GVK, ...props, @@ -8795,9 +9407,9 @@ export class KubeCsiDriverListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.CSIDriverList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSIDriverList', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSIDriverList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.CSIDriverList". @@ -8819,7 +9431,11 @@ export class KubeCsiDriverListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiDriverListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiDriverListV1Beta1Props + ) { super(scope, id, { ...KubeCsiDriverListV1Beta1.GVK, ...props, @@ -8849,9 +9465,9 @@ export class KubeCsiNodeV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.CSINode" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSINode', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSINode", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.CSINode". @@ -8873,7 +9489,11 @@ export class KubeCsiNodeV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiNodeV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiNodeV1Beta1Props + ) { super(scope, id, { ...KubeCsiNodeV1Beta1.GVK, ...props, @@ -8903,9 +9523,9 @@ export class KubeCsiNodeListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.CSINodeList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSINodeList', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSINodeList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.CSINodeList". @@ -8927,7 +9547,11 @@ export class KubeCsiNodeListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiNodeListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiNodeListV1Beta1Props + ) { super(scope, id, { ...KubeCsiNodeListV1Beta1.GVK, ...props, @@ -8965,9 +9589,9 @@ export class KubeCsiStorageCapacityV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.CSIStorageCapacity" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSIStorageCapacity', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSIStorageCapacity", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.CSIStorageCapacity". @@ -8989,7 +9613,11 @@ export class KubeCsiStorageCapacityV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiStorageCapacityV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiStorageCapacityV1Beta1Props + ) { super(scope, id, { ...KubeCsiStorageCapacityV1Beta1.GVK, ...props, @@ -9019,9 +9647,9 @@ export class KubeCsiStorageCapacityListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.CSIStorageCapacityList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'CSIStorageCapacityList', - } + apiVersion: "storage.k8s.io/v1", + kind: "CSIStorageCapacityList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.CSIStorageCapacityList". @@ -9043,7 +9671,11 @@ export class KubeCsiStorageCapacityListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCsiStorageCapacityListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCsiStorageCapacityListV1Beta1Props + ) { super(scope, id, { ...KubeCsiStorageCapacityListV1Beta1.GVK, ...props, @@ -9075,9 +9707,9 @@ export class KubeStorageClassV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.StorageClass" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'StorageClass', - } + apiVersion: "storage.k8s.io/v1", + kind: "StorageClass", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.StorageClass". @@ -9099,7 +9731,11 @@ export class KubeStorageClassV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeStorageClassV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeStorageClassV1Beta1Props + ) { super(scope, id, { ...KubeStorageClassV1Beta1.GVK, ...props, @@ -9129,9 +9765,9 @@ export class KubeStorageClassListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.StorageClassList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'StorageClassList', - } + apiVersion: "storage.k8s.io/v1", + kind: "StorageClassList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.StorageClassList". @@ -9153,7 +9789,11 @@ export class KubeStorageClassListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeStorageClassListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeStorageClassListV1Beta1Props + ) { super(scope, id, { ...KubeStorageClassListV1Beta1.GVK, ...props, @@ -9185,9 +9825,9 @@ export class KubeVolumeAttachmentV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.VolumeAttachment" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'VolumeAttachment', - } + apiVersion: "storage.k8s.io/v1", + kind: "VolumeAttachment", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.VolumeAttachment". @@ -9209,7 +9849,11 @@ export class KubeVolumeAttachmentV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeVolumeAttachmentV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeVolumeAttachmentV1Beta1Props + ) { super(scope, id, { ...KubeVolumeAttachmentV1Beta1.GVK, ...props, @@ -9239,9 +9883,9 @@ export class KubeVolumeAttachmentListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.api.storage.v1beta1.VolumeAttachmentList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'storage.k8s.io/v1', - kind: 'VolumeAttachmentList', - } + apiVersion: "storage.k8s.io/v1", + kind: "VolumeAttachmentList", + }; /** * Renders a Kubernetes manifest for "io.k8s.api.storage.v1beta1.VolumeAttachmentList". @@ -9263,7 +9907,11 @@ export class KubeVolumeAttachmentListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeVolumeAttachmentListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeVolumeAttachmentListV1Beta1Props + ) { super(scope, id, { ...KubeVolumeAttachmentListV1Beta1.GVK, ...props, @@ -9293,9 +9941,9 @@ export class KubeCustomResourceDefinition extends ApiObject { * Returns the apiVersion and kind for "io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceDefinition" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apiextensions.k8s.io/v1', - kind: 'CustomResourceDefinition', - } + apiVersion: "apiextensions.k8s.io/v1", + kind: "CustomResourceDefinition", + }; /** * Renders a Kubernetes manifest for "io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceDefinition". @@ -9317,7 +9965,11 @@ export class KubeCustomResourceDefinition extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCustomResourceDefinitionProps) { + public constructor( + scope: Construct, + id: string, + props: KubeCustomResourceDefinitionProps + ) { super(scope, id, { ...KubeCustomResourceDefinition.GVK, ...props, @@ -9347,9 +9999,9 @@ export class KubeCustomResourceDefinitionList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceDefinitionList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apiextensions.k8s.io/v1', - kind: 'CustomResourceDefinitionList', - } + apiVersion: "apiextensions.k8s.io/v1", + kind: "CustomResourceDefinitionList", + }; /** * Renders a Kubernetes manifest for "io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceDefinitionList". @@ -9371,7 +10023,11 @@ export class KubeCustomResourceDefinitionList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCustomResourceDefinitionListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeCustomResourceDefinitionListProps + ) { super(scope, id, { ...KubeCustomResourceDefinitionList.GVK, ...props, @@ -9401,9 +10057,9 @@ export class KubeCustomResourceDefinitionV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceDefinition" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apiextensions.k8s.io/v1', - kind: 'CustomResourceDefinition', - } + apiVersion: "apiextensions.k8s.io/v1", + kind: "CustomResourceDefinition", + }; /** * Renders a Kubernetes manifest for "io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceDefinition". @@ -9425,7 +10081,11 @@ export class KubeCustomResourceDefinitionV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCustomResourceDefinitionV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCustomResourceDefinitionV1Beta1Props + ) { super(scope, id, { ...KubeCustomResourceDefinitionV1Beta1.GVK, ...props, @@ -9455,9 +10115,9 @@ export class KubeCustomResourceDefinitionListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceDefinitionList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apiextensions.k8s.io/v1', - kind: 'CustomResourceDefinitionList', - } + apiVersion: "apiextensions.k8s.io/v1", + kind: "CustomResourceDefinitionList", + }; /** * Renders a Kubernetes manifest for "io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceDefinitionList". @@ -9466,7 +10126,9 @@ export class KubeCustomResourceDefinitionListV1Beta1 extends ApiObject { * * @param props initialization props */ - public static manifest(props: KubeCustomResourceDefinitionListV1Beta1Props): any { + public static manifest( + props: KubeCustomResourceDefinitionListV1Beta1Props + ): any { return { ...KubeCustomResourceDefinitionListV1Beta1.GVK, ...toJson_KubeCustomResourceDefinitionListV1Beta1Props(props), @@ -9479,7 +10141,11 @@ export class KubeCustomResourceDefinitionListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeCustomResourceDefinitionListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeCustomResourceDefinitionListV1Beta1Props + ) { super(scope, id, { ...KubeCustomResourceDefinitionListV1Beta1.GVK, ...props, @@ -9509,9 +10175,9 @@ export class KubeStatus extends ApiObject { * Returns the apiVersion and kind for "io.k8s.apimachinery.pkg.apis.meta.v1.Status" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'v1', - kind: 'Status', - } + apiVersion: "v1", + kind: "Status", + }; /** * Renders a Kubernetes manifest for "io.k8s.apimachinery.pkg.apis.meta.v1.Status". @@ -9533,7 +10199,11 @@ export class KubeStatus extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeStatusProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeStatusProps = {} + ) { super(scope, id, { ...KubeStatus.GVK, ...props, @@ -9563,9 +10233,9 @@ export class KubeApiService extends ApiObject { * Returns the apiVersion and kind for "io.k8s.kube-aggregator.pkg.apis.apiregistration.v1.APIService" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apiregistration.k8s.io/v1', - kind: 'APIService', - } + apiVersion: "apiregistration.k8s.io/v1", + kind: "APIService", + }; /** * Renders a Kubernetes manifest for "io.k8s.kube-aggregator.pkg.apis.apiregistration.v1.APIService". @@ -9587,7 +10257,11 @@ export class KubeApiService extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeApiServiceProps = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeApiServiceProps = {} + ) { super(scope, id, { ...KubeApiService.GVK, ...props, @@ -9617,9 +10291,9 @@ export class KubeApiServiceList extends ApiObject { * Returns the apiVersion and kind for "io.k8s.kube-aggregator.pkg.apis.apiregistration.v1.APIServiceList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apiregistration.k8s.io/v1', - kind: 'APIServiceList', - } + apiVersion: "apiregistration.k8s.io/v1", + kind: "APIServiceList", + }; /** * Renders a Kubernetes manifest for "io.k8s.kube-aggregator.pkg.apis.apiregistration.v1.APIServiceList". @@ -9641,7 +10315,11 @@ export class KubeApiServiceList extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeApiServiceListProps) { + public constructor( + scope: Construct, + id: string, + props: KubeApiServiceListProps + ) { super(scope, id, { ...KubeApiServiceList.GVK, ...props, @@ -9671,9 +10349,9 @@ export class KubeApiServiceV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.kube-aggregator.pkg.apis.apiregistration.v1beta1.APIService" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apiregistration.k8s.io/v1', - kind: 'APIService', - } + apiVersion: "apiregistration.k8s.io/v1", + kind: "APIService", + }; /** * Renders a Kubernetes manifest for "io.k8s.kube-aggregator.pkg.apis.apiregistration.v1beta1.APIService". @@ -9695,7 +10373,11 @@ export class KubeApiServiceV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeApiServiceV1Beta1Props = {}) { + public constructor( + scope: Construct, + id: string, + props: KubeApiServiceV1Beta1Props = {} + ) { super(scope, id, { ...KubeApiServiceV1Beta1.GVK, ...props, @@ -9725,9 +10407,9 @@ export class KubeApiServiceListV1Beta1 extends ApiObject { * Returns the apiVersion and kind for "io.k8s.kube-aggregator.pkg.apis.apiregistration.v1beta1.APIServiceList" */ public static readonly GVK: GroupVersionKind = { - apiVersion: 'apiregistration.k8s.io/v1', - kind: 'APIServiceList', - } + apiVersion: "apiregistration.k8s.io/v1", + kind: "APIServiceList", + }; /** * Renders a Kubernetes manifest for "io.k8s.kube-aggregator.pkg.apis.apiregistration.v1beta1.APIServiceList". @@ -9749,7 +10431,11 @@ export class KubeApiServiceListV1Beta1 extends ApiObject { * @param id a scope-local name for the object * @param props initialization props */ - public constructor(scope: Construct, id: string, props: KubeApiServiceListV1Beta1Props) { + public constructor( + scope: Construct, + id: string, + props: KubeApiServiceListV1Beta1Props + ) { super(scope, id, { ...KubeApiServiceListV1Beta1.GVK, ...props, @@ -9788,21 +10474,27 @@ export interface KubeMutatingWebhookConfigurationProps { * @schema io.k8s.api.admissionregistration.v1.MutatingWebhookConfiguration#webhooks */ readonly webhooks?: MutatingWebhook[]; - } /** * Converts an object of type 'KubeMutatingWebhookConfigurationProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeMutatingWebhookConfigurationProps(obj: KubeMutatingWebhookConfigurationProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeMutatingWebhookConfigurationProps( + obj: KubeMutatingWebhookConfigurationProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'webhooks': obj.webhooks?.map(y => toJson_MutatingWebhook(y)), + metadata: toJson_ObjectMeta(obj.metadata), + webhooks: obj.webhooks?.map((y) => toJson_MutatingWebhook(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -9825,21 +10517,29 @@ export interface KubeMutatingWebhookConfigurationListProps { * @schema io.k8s.api.admissionregistration.v1.MutatingWebhookConfigurationList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeMutatingWebhookConfigurationListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeMutatingWebhookConfigurationListProps(obj: KubeMutatingWebhookConfigurationListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeMutatingWebhookConfigurationListProps( + obj: KubeMutatingWebhookConfigurationListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeMutatingWebhookConfigurationProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => + toJson_KubeMutatingWebhookConfigurationProps(y) + ), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -9862,21 +10562,27 @@ export interface KubeValidatingWebhookConfigurationProps { * @schema io.k8s.api.admissionregistration.v1.ValidatingWebhookConfiguration#webhooks */ readonly webhooks?: ValidatingWebhook[]; - } /** * Converts an object of type 'KubeValidatingWebhookConfigurationProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeValidatingWebhookConfigurationProps(obj: KubeValidatingWebhookConfigurationProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeValidatingWebhookConfigurationProps( + obj: KubeValidatingWebhookConfigurationProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'webhooks': obj.webhooks?.map(y => toJson_ValidatingWebhook(y)), + metadata: toJson_ObjectMeta(obj.metadata), + webhooks: obj.webhooks?.map((y) => toJson_ValidatingWebhook(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -9899,21 +10605,29 @@ export interface KubeValidatingWebhookConfigurationListProps { * @schema io.k8s.api.admissionregistration.v1.ValidatingWebhookConfigurationList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeValidatingWebhookConfigurationListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeValidatingWebhookConfigurationListProps(obj: KubeValidatingWebhookConfigurationListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeValidatingWebhookConfigurationListProps( + obj: KubeValidatingWebhookConfigurationListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeValidatingWebhookConfigurationProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => + toJson_KubeValidatingWebhookConfigurationProps(y) + ), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -9936,21 +10650,27 @@ export interface KubeMutatingWebhookConfigurationV1Beta1Props { * @schema io.k8s.api.admissionregistration.v1beta1.MutatingWebhookConfiguration#webhooks */ readonly webhooks?: MutatingWebhookV1Beta1[]; - } /** * Converts an object of type 'KubeMutatingWebhookConfigurationV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeMutatingWebhookConfigurationV1Beta1Props(obj: KubeMutatingWebhookConfigurationV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeMutatingWebhookConfigurationV1Beta1Props( + obj: KubeMutatingWebhookConfigurationV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'webhooks': obj.webhooks?.map(y => toJson_MutatingWebhookV1Beta1(y)), + metadata: toJson_ObjectMeta(obj.metadata), + webhooks: obj.webhooks?.map((y) => toJson_MutatingWebhookV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -9973,21 +10693,29 @@ export interface KubeMutatingWebhookConfigurationListV1Beta1Props { * @schema io.k8s.api.admissionregistration.v1beta1.MutatingWebhookConfigurationList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeMutatingWebhookConfigurationListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeMutatingWebhookConfigurationListV1Beta1Props(obj: KubeMutatingWebhookConfigurationListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeMutatingWebhookConfigurationListV1Beta1Props( + obj: KubeMutatingWebhookConfigurationListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeMutatingWebhookConfigurationV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => + toJson_KubeMutatingWebhookConfigurationV1Beta1Props(y) + ), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10010,21 +10738,27 @@ export interface KubeValidatingWebhookConfigurationV1Beta1Props { * @schema io.k8s.api.admissionregistration.v1beta1.ValidatingWebhookConfiguration#webhooks */ readonly webhooks?: ValidatingWebhookV1Beta1[]; - } /** * Converts an object of type 'KubeValidatingWebhookConfigurationV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeValidatingWebhookConfigurationV1Beta1Props(obj: KubeValidatingWebhookConfigurationV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeValidatingWebhookConfigurationV1Beta1Props( + obj: KubeValidatingWebhookConfigurationV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'webhooks': obj.webhooks?.map(y => toJson_ValidatingWebhookV1Beta1(y)), + metadata: toJson_ObjectMeta(obj.metadata), + webhooks: obj.webhooks?.map((y) => toJson_ValidatingWebhookV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10047,21 +10781,29 @@ export interface KubeValidatingWebhookConfigurationListV1Beta1Props { * @schema io.k8s.api.admissionregistration.v1beta1.ValidatingWebhookConfigurationList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeValidatingWebhookConfigurationListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeValidatingWebhookConfigurationListV1Beta1Props(obj: KubeValidatingWebhookConfigurationListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeValidatingWebhookConfigurationListV1Beta1Props( + obj: KubeValidatingWebhookConfigurationListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeValidatingWebhookConfigurationV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => + toJson_KubeValidatingWebhookConfigurationV1Beta1Props(y) + ), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10085,21 +10827,27 @@ export interface KubeStorageVersionV1Alpha1Props { * @schema io.k8s.api.apiserverinternal.v1alpha1.StorageVersion#spec */ readonly spec: any; - } /** * Converts an object of type 'KubeStorageVersionV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeStorageVersionV1Alpha1Props(obj: KubeStorageVersionV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeStorageVersionV1Alpha1Props( + obj: KubeStorageVersionV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': obj.spec, + metadata: toJson_ObjectMeta(obj.metadata), + spec: obj.spec, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10118,21 +10866,27 @@ export interface KubeStorageVersionListV1Alpha1Props { * @schema io.k8s.api.apiserverinternal.v1alpha1.StorageVersionList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeStorageVersionListV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeStorageVersionListV1Alpha1Props(obj: KubeStorageVersionListV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeStorageVersionListV1Alpha1Props( + obj: KubeStorageVersionListV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeStorageVersionV1Alpha1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeStorageVersionV1Alpha1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10162,22 +10916,28 @@ export interface KubeControllerRevisionProps { * @schema io.k8s.api.apps.v1.ControllerRevision#revision */ readonly revision: number; - } /** * Converts an object of type 'KubeControllerRevisionProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeControllerRevisionProps(obj: KubeControllerRevisionProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeControllerRevisionProps( + obj: KubeControllerRevisionProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'data': obj.data, - 'metadata': toJson_ObjectMeta(obj.metadata), - 'revision': obj.revision, + data: obj.data, + metadata: toJson_ObjectMeta(obj.metadata), + revision: obj.revision, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10200,21 +10960,27 @@ export interface KubeControllerRevisionListProps { * @schema io.k8s.api.apps.v1.ControllerRevisionList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeControllerRevisionListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeControllerRevisionListProps(obj: KubeControllerRevisionListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeControllerRevisionListProps( + obj: KubeControllerRevisionListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeControllerRevisionProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeControllerRevisionProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10237,21 +11003,27 @@ export interface KubeDaemonSetProps { * @schema io.k8s.api.apps.v1.DaemonSet#spec */ readonly spec?: DaemonSetSpec; - } /** * Converts an object of type 'KubeDaemonSetProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeDaemonSetProps(obj: KubeDaemonSetProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeDaemonSetProps( + obj: KubeDaemonSetProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_DaemonSetSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_DaemonSetSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10274,21 +11046,27 @@ export interface KubeDaemonSetListProps { * @schema io.k8s.api.apps.v1.DaemonSetList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeDaemonSetListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeDaemonSetListProps(obj: KubeDaemonSetListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeDaemonSetListProps( + obj: KubeDaemonSetListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeDaemonSetProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeDaemonSetProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10311,21 +11089,27 @@ export interface KubeDeploymentProps { * @schema io.k8s.api.apps.v1.Deployment#spec */ readonly spec?: DeploymentSpec; - } /** * Converts an object of type 'KubeDeploymentProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeDeploymentProps(obj: KubeDeploymentProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeDeploymentProps( + obj: KubeDeploymentProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_DeploymentSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_DeploymentSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10348,21 +11132,27 @@ export interface KubeDeploymentListProps { * @schema io.k8s.api.apps.v1.DeploymentList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeDeploymentListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeDeploymentListProps(obj: KubeDeploymentListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeDeploymentListProps( + obj: KubeDeploymentListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeDeploymentProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeDeploymentProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10385,21 +11175,27 @@ export interface KubeReplicaSetProps { * @schema io.k8s.api.apps.v1.ReplicaSet#spec */ readonly spec?: ReplicaSetSpec; - } /** * Converts an object of type 'KubeReplicaSetProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeReplicaSetProps(obj: KubeReplicaSetProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeReplicaSetProps( + obj: KubeReplicaSetProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_ReplicaSetSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_ReplicaSetSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10422,21 +11218,27 @@ export interface KubeReplicaSetListProps { * @schema io.k8s.api.apps.v1.ReplicaSetList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeReplicaSetListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeReplicaSetListProps(obj: KubeReplicaSetListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeReplicaSetListProps( + obj: KubeReplicaSetListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeReplicaSetProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeReplicaSetProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10460,21 +11262,27 @@ export interface KubeStatefulSetProps { * @schema io.k8s.api.apps.v1.StatefulSet#spec */ readonly spec?: StatefulSetSpec; - } /** * Converts an object of type 'KubeStatefulSetProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeStatefulSetProps(obj: KubeStatefulSetProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeStatefulSetProps( + obj: KubeStatefulSetProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_StatefulSetSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_StatefulSetSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10493,21 +11301,27 @@ export interface KubeStatefulSetListProps { * @schema io.k8s.api.apps.v1.StatefulSetList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeStatefulSetListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeStatefulSetListProps(obj: KubeStatefulSetListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeStatefulSetListProps( + obj: KubeStatefulSetListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeStatefulSetProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeStatefulSetProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10526,21 +11340,27 @@ export interface KubeTokenRequestProps { * @schema io.k8s.api.authentication.v1.TokenRequest#spec */ readonly spec: TokenRequestSpec; - } /** * Converts an object of type 'KubeTokenRequestProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeTokenRequestProps(obj: KubeTokenRequestProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeTokenRequestProps( + obj: KubeTokenRequestProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_TokenRequestSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_TokenRequestSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10561,21 +11381,27 @@ export interface KubeTokenReviewProps { * @schema io.k8s.api.authentication.v1.TokenReview#spec */ readonly spec: TokenReviewSpec; - } /** * Converts an object of type 'KubeTokenReviewProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeTokenReviewProps(obj: KubeTokenReviewProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeTokenReviewProps( + obj: KubeTokenReviewProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_TokenReviewSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_TokenReviewSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10596,21 +11422,27 @@ export interface KubeTokenReviewV1Beta1Props { * @schema io.k8s.api.authentication.v1beta1.TokenReview#spec */ readonly spec: TokenReviewSpecV1Beta1; - } /** * Converts an object of type 'KubeTokenReviewV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeTokenReviewV1Beta1Props(obj: KubeTokenReviewV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeTokenReviewV1Beta1Props( + obj: KubeTokenReviewV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_TokenReviewSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_TokenReviewSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10631,21 +11463,27 @@ export interface KubeLocalSubjectAccessReviewProps { * @schema io.k8s.api.authorization.v1.LocalSubjectAccessReview#spec */ readonly spec: SubjectAccessReviewSpec; - } /** * Converts an object of type 'KubeLocalSubjectAccessReviewProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeLocalSubjectAccessReviewProps(obj: KubeLocalSubjectAccessReviewProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeLocalSubjectAccessReviewProps( + obj: KubeLocalSubjectAccessReviewProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_SubjectAccessReviewSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_SubjectAccessReviewSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10666,21 +11504,27 @@ export interface KubeSelfSubjectAccessReviewProps { * @schema io.k8s.api.authorization.v1.SelfSubjectAccessReview#spec */ readonly spec: SelfSubjectAccessReviewSpec; - } /** * Converts an object of type 'KubeSelfSubjectAccessReviewProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeSelfSubjectAccessReviewProps(obj: KubeSelfSubjectAccessReviewProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeSelfSubjectAccessReviewProps( + obj: KubeSelfSubjectAccessReviewProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_SelfSubjectAccessReviewSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_SelfSubjectAccessReviewSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10701,21 +11545,27 @@ export interface KubeSelfSubjectRulesReviewProps { * @schema io.k8s.api.authorization.v1.SelfSubjectRulesReview#spec */ readonly spec: SelfSubjectRulesReviewSpec; - } /** * Converts an object of type 'KubeSelfSubjectRulesReviewProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeSelfSubjectRulesReviewProps(obj: KubeSelfSubjectRulesReviewProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeSelfSubjectRulesReviewProps( + obj: KubeSelfSubjectRulesReviewProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_SelfSubjectRulesReviewSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_SelfSubjectRulesReviewSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10736,21 +11586,27 @@ export interface KubeSubjectAccessReviewProps { * @schema io.k8s.api.authorization.v1.SubjectAccessReview#spec */ readonly spec: SubjectAccessReviewSpec; - } /** * Converts an object of type 'KubeSubjectAccessReviewProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeSubjectAccessReviewProps(obj: KubeSubjectAccessReviewProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeSubjectAccessReviewProps( + obj: KubeSubjectAccessReviewProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_SubjectAccessReviewSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_SubjectAccessReviewSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10771,21 +11627,27 @@ export interface KubeLocalSubjectAccessReviewV1Beta1Props { * @schema io.k8s.api.authorization.v1beta1.LocalSubjectAccessReview#spec */ readonly spec: SubjectAccessReviewSpecV1Beta1; - } /** * Converts an object of type 'KubeLocalSubjectAccessReviewV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeLocalSubjectAccessReviewV1Beta1Props(obj: KubeLocalSubjectAccessReviewV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeLocalSubjectAccessReviewV1Beta1Props( + obj: KubeLocalSubjectAccessReviewV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_SubjectAccessReviewSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_SubjectAccessReviewSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10806,21 +11668,27 @@ export interface KubeSelfSubjectAccessReviewV1Beta1Props { * @schema io.k8s.api.authorization.v1beta1.SelfSubjectAccessReview#spec */ readonly spec: SelfSubjectAccessReviewSpecV1Beta1; - } /** * Converts an object of type 'KubeSelfSubjectAccessReviewV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeSelfSubjectAccessReviewV1Beta1Props(obj: KubeSelfSubjectAccessReviewV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeSelfSubjectAccessReviewV1Beta1Props( + obj: KubeSelfSubjectAccessReviewV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_SelfSubjectAccessReviewSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_SelfSubjectAccessReviewSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10841,21 +11709,27 @@ export interface KubeSelfSubjectRulesReviewV1Beta1Props { * @schema io.k8s.api.authorization.v1beta1.SelfSubjectRulesReview#spec */ readonly spec: SelfSubjectRulesReviewSpecV1Beta1; - } /** * Converts an object of type 'KubeSelfSubjectRulesReviewV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeSelfSubjectRulesReviewV1Beta1Props(obj: KubeSelfSubjectRulesReviewV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeSelfSubjectRulesReviewV1Beta1Props( + obj: KubeSelfSubjectRulesReviewV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_SelfSubjectRulesReviewSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_SelfSubjectRulesReviewSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10876,21 +11750,27 @@ export interface KubeSubjectAccessReviewV1Beta1Props { * @schema io.k8s.api.authorization.v1beta1.SubjectAccessReview#spec */ readonly spec: SubjectAccessReviewSpecV1Beta1; - } /** * Converts an object of type 'KubeSubjectAccessReviewV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeSubjectAccessReviewV1Beta1Props(obj: KubeSubjectAccessReviewV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeSubjectAccessReviewV1Beta1Props( + obj: KubeSubjectAccessReviewV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_SubjectAccessReviewSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_SubjectAccessReviewSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10913,21 +11793,27 @@ export interface KubeHorizontalPodAutoscalerProps { * @schema io.k8s.api.autoscaling.v1.HorizontalPodAutoscaler#spec */ readonly spec?: HorizontalPodAutoscalerSpec; - } /** * Converts an object of type 'KubeHorizontalPodAutoscalerProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeHorizontalPodAutoscalerProps(obj: KubeHorizontalPodAutoscalerProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeHorizontalPodAutoscalerProps( + obj: KubeHorizontalPodAutoscalerProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_HorizontalPodAutoscalerSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_HorizontalPodAutoscalerSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10950,21 +11836,27 @@ export interface KubeHorizontalPodAutoscalerListProps { * @schema io.k8s.api.autoscaling.v1.HorizontalPodAutoscalerList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeHorizontalPodAutoscalerListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeHorizontalPodAutoscalerListProps(obj: KubeHorizontalPodAutoscalerListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeHorizontalPodAutoscalerListProps( + obj: KubeHorizontalPodAutoscalerListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeHorizontalPodAutoscalerProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeHorizontalPodAutoscalerProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -10987,21 +11879,27 @@ export interface KubeScaleProps { * @schema io.k8s.api.autoscaling.v1.Scale#spec */ readonly spec?: ScaleSpec; - } /** * Converts an object of type 'KubeScaleProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeScaleProps(obj: KubeScaleProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeScaleProps( + obj: KubeScaleProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_ScaleSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_ScaleSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11024,21 +11922,27 @@ export interface KubeHorizontalPodAutoscalerV2Beta1Props { * @schema io.k8s.api.autoscaling.v2beta1.HorizontalPodAutoscaler#spec */ readonly spec?: HorizontalPodAutoscalerSpecV2Beta1; - } /** * Converts an object of type 'KubeHorizontalPodAutoscalerV2Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeHorizontalPodAutoscalerV2Beta1Props(obj: KubeHorizontalPodAutoscalerV2Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeHorizontalPodAutoscalerV2Beta1Props( + obj: KubeHorizontalPodAutoscalerV2Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_HorizontalPodAutoscalerSpecV2Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_HorizontalPodAutoscalerSpecV2Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11061,21 +11965,29 @@ export interface KubeHorizontalPodAutoscalerListV2Beta1Props { * @schema io.k8s.api.autoscaling.v2beta1.HorizontalPodAutoscalerList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeHorizontalPodAutoscalerListV2Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeHorizontalPodAutoscalerListV2Beta1Props(obj: KubeHorizontalPodAutoscalerListV2Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeHorizontalPodAutoscalerListV2Beta1Props( + obj: KubeHorizontalPodAutoscalerListV2Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeHorizontalPodAutoscalerV2Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => + toJson_KubeHorizontalPodAutoscalerV2Beta1Props(y) + ), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11098,21 +12010,27 @@ export interface KubeHorizontalPodAutoscalerV2Beta2Props { * @schema io.k8s.api.autoscaling.v2beta2.HorizontalPodAutoscaler#spec */ readonly spec?: HorizontalPodAutoscalerSpecV2Beta2; - } /** * Converts an object of type 'KubeHorizontalPodAutoscalerV2Beta2Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeHorizontalPodAutoscalerV2Beta2Props(obj: KubeHorizontalPodAutoscalerV2Beta2Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeHorizontalPodAutoscalerV2Beta2Props( + obj: KubeHorizontalPodAutoscalerV2Beta2Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_HorizontalPodAutoscalerSpecV2Beta2(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_HorizontalPodAutoscalerSpecV2Beta2(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11135,21 +12053,29 @@ export interface KubeHorizontalPodAutoscalerListV2Beta2Props { * @schema io.k8s.api.autoscaling.v2beta2.HorizontalPodAutoscalerList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeHorizontalPodAutoscalerListV2Beta2Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeHorizontalPodAutoscalerListV2Beta2Props(obj: KubeHorizontalPodAutoscalerListV2Beta2Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeHorizontalPodAutoscalerListV2Beta2Props( + obj: KubeHorizontalPodAutoscalerListV2Beta2Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeHorizontalPodAutoscalerV2Beta2Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => + toJson_KubeHorizontalPodAutoscalerV2Beta2Props(y) + ), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11172,21 +12098,27 @@ export interface KubeCronJobProps { * @schema io.k8s.api.batch.v1.CronJob#spec */ readonly spec?: CronJobSpec; - } /** * Converts an object of type 'KubeCronJobProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCronJobProps(obj: KubeCronJobProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCronJobProps( + obj: KubeCronJobProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CronJobSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CronJobSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11209,21 +12141,27 @@ export interface KubeCronJobListProps { * @schema io.k8s.api.batch.v1.CronJobList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCronJobListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCronJobListProps(obj: KubeCronJobListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCronJobListProps( + obj: KubeCronJobListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCronJobProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCronJobProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11246,21 +12184,27 @@ export interface KubeJobProps { * @schema io.k8s.api.batch.v1.Job#spec */ readonly spec?: JobSpec; - } /** * Converts an object of type 'KubeJobProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeJobProps(obj: KubeJobProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeJobProps( + obj: KubeJobProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_JobSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_JobSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11283,21 +12227,27 @@ export interface KubeJobListProps { * @schema io.k8s.api.batch.v1.JobList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeJobListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeJobListProps(obj: KubeJobListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeJobListProps( + obj: KubeJobListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeJobProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeJobProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11320,21 +12270,27 @@ export interface KubeCronJobV1Beta1Props { * @schema io.k8s.api.batch.v1beta1.CronJob#spec */ readonly spec?: CronJobSpecV1Beta1; - } /** * Converts an object of type 'KubeCronJobV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCronJobV1Beta1Props(obj: KubeCronJobV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCronJobV1Beta1Props( + obj: KubeCronJobV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CronJobSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CronJobSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11357,21 +12313,27 @@ export interface KubeCronJobListV1Beta1Props { * @schema io.k8s.api.batch.v1beta1.CronJobList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCronJobListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCronJobListV1Beta1Props(obj: KubeCronJobListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCronJobListV1Beta1Props( + obj: KubeCronJobListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCronJobV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCronJobV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11398,21 +12360,27 @@ export interface KubeCertificateSigningRequestProps { * @schema io.k8s.api.certificates.v1.CertificateSigningRequest#spec */ readonly spec: CertificateSigningRequestSpec; - } /** * Converts an object of type 'KubeCertificateSigningRequestProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCertificateSigningRequestProps(obj: KubeCertificateSigningRequestProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCertificateSigningRequestProps( + obj: KubeCertificateSigningRequestProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CertificateSigningRequestSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CertificateSigningRequestSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11433,21 +12401,27 @@ export interface KubeCertificateSigningRequestListProps { * @schema io.k8s.api.certificates.v1.CertificateSigningRequestList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCertificateSigningRequestListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCertificateSigningRequestListProps(obj: KubeCertificateSigningRequestListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCertificateSigningRequestListProps( + obj: KubeCertificateSigningRequestListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCertificateSigningRequestProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCertificateSigningRequestProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11468,21 +12442,27 @@ export interface KubeCertificateSigningRequestV1Beta1Props { * @schema io.k8s.api.certificates.v1beta1.CertificateSigningRequest#spec */ readonly spec?: CertificateSigningRequestSpecV1Beta1; - } /** * Converts an object of type 'KubeCertificateSigningRequestV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCertificateSigningRequestV1Beta1Props(obj: KubeCertificateSigningRequestV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCertificateSigningRequestV1Beta1Props( + obj: KubeCertificateSigningRequestV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CertificateSigningRequestSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CertificateSigningRequestSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11499,21 +12479,29 @@ export interface KubeCertificateSigningRequestListV1Beta1Props { * @schema io.k8s.api.certificates.v1beta1.CertificateSigningRequestList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCertificateSigningRequestListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCertificateSigningRequestListV1Beta1Props(obj: KubeCertificateSigningRequestListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCertificateSigningRequestListV1Beta1Props( + obj: KubeCertificateSigningRequestListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCertificateSigningRequestV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => + toJson_KubeCertificateSigningRequestV1Beta1Props(y) + ), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11536,21 +12524,27 @@ export interface KubeLeaseProps { * @schema io.k8s.api.coordination.v1.Lease#spec */ readonly spec?: LeaseSpec; - } /** * Converts an object of type 'KubeLeaseProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeLeaseProps(obj: KubeLeaseProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeLeaseProps( + obj: KubeLeaseProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_LeaseSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_LeaseSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11573,21 +12567,27 @@ export interface KubeLeaseListProps { * @schema io.k8s.api.coordination.v1.LeaseList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeLeaseListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeLeaseListProps(obj: KubeLeaseListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeLeaseListProps( + obj: KubeLeaseListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeLeaseProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeLeaseProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11610,21 +12610,27 @@ export interface KubeLeaseV1Beta1Props { * @schema io.k8s.api.coordination.v1beta1.Lease#spec */ readonly spec?: LeaseSpecV1Beta1; - } /** * Converts an object of type 'KubeLeaseV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeLeaseV1Beta1Props(obj: KubeLeaseV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeLeaseV1Beta1Props( + obj: KubeLeaseV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_LeaseSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_LeaseSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11647,21 +12653,27 @@ export interface KubeLeaseListV1Beta1Props { * @schema io.k8s.api.coordination.v1beta1.LeaseList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeLeaseListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeLeaseListV1Beta1Props(obj: KubeLeaseListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeLeaseListV1Beta1Props( + obj: KubeLeaseListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeLeaseV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeLeaseV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11684,21 +12696,27 @@ export interface KubeBindingProps { * @schema io.k8s.api.core.v1.Binding#target */ readonly target: ObjectReference; - } /** * Converts an object of type 'KubeBindingProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeBindingProps(obj: KubeBindingProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeBindingProps( + obj: KubeBindingProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'target': toJson_ObjectReference(obj.target), + metadata: toJson_ObjectMeta(obj.metadata), + target: toJson_ObjectReference(obj.target), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11721,21 +12739,27 @@ export interface KubeComponentStatusProps { * @schema io.k8s.api.core.v1.ComponentStatus#metadata */ readonly metadata?: ObjectMeta; - } /** * Converts an object of type 'KubeComponentStatusProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeComponentStatusProps(obj: KubeComponentStatusProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeComponentStatusProps( + obj: KubeComponentStatusProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'conditions': obj.conditions?.map(y => toJson_ComponentCondition(y)), - 'metadata': toJson_ObjectMeta(obj.metadata), + conditions: obj.conditions?.map((y) => toJson_ComponentCondition(y)), + metadata: toJson_ObjectMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11758,21 +12782,27 @@ export interface KubeComponentStatusListProps { * @schema io.k8s.api.core.v1.ComponentStatusList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeComponentStatusListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeComponentStatusListProps(obj: KubeComponentStatusListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeComponentStatusListProps( + obj: KubeComponentStatusListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeComponentStatusProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeComponentStatusProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11809,23 +12839,41 @@ export interface KubeConfigMapProps { * @schema io.k8s.api.core.v1.ConfigMap#metadata */ readonly metadata?: ObjectMeta; - } /** * Converts an object of type 'KubeConfigMapProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeConfigMapProps(obj: KubeConfigMapProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeConfigMapProps( + obj: KubeConfigMapProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'binaryData': ((obj.binaryData) === undefined) ? undefined : (Object.entries(obj.binaryData).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'data': ((obj.data) === undefined) ? undefined : (Object.entries(obj.data).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'immutable': obj.immutable, - 'metadata': toJson_ObjectMeta(obj.metadata), + binaryData: + obj.binaryData === undefined + ? undefined + : Object.entries(obj.binaryData).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + data: + obj.data === undefined + ? undefined + : Object.entries(obj.data).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + immutable: obj.immutable, + metadata: toJson_ObjectMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11848,21 +12896,27 @@ export interface KubeConfigMapListProps { * @schema io.k8s.api.core.v1.ConfigMapList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeConfigMapListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeConfigMapListProps(obj: KubeConfigMapListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeConfigMapListProps( + obj: KubeConfigMapListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeConfigMapProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeConfigMapProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11896,21 +12950,27 @@ export interface KubeEndpointsProps { * @schema io.k8s.api.core.v1.Endpoints#subsets */ readonly subsets?: EndpointSubset[]; - } /** * Converts an object of type 'KubeEndpointsProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEndpointsProps(obj: KubeEndpointsProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEndpointsProps( + obj: KubeEndpointsProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'subsets': obj.subsets?.map(y => toJson_EndpointSubset(y)), + metadata: toJson_ObjectMeta(obj.metadata), + subsets: obj.subsets?.map((y) => toJson_EndpointSubset(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11933,21 +12993,27 @@ export interface KubeEndpointsListProps { * @schema io.k8s.api.core.v1.EndpointsList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeEndpointsListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEndpointsListProps(obj: KubeEndpointsListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEndpointsListProps( + obj: KubeEndpointsListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeEndpointsProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeEndpointsProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -11968,21 +13034,29 @@ export interface KubeEphemeralContainersProps { * @schema io.k8s.api.core.v1.EphemeralContainers#metadata */ readonly metadata?: ObjectMeta; - } /** * Converts an object of type 'KubeEphemeralContainersProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEphemeralContainersProps(obj: KubeEphemeralContainersProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEphemeralContainersProps( + obj: KubeEphemeralContainersProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'ephemeralContainers': obj.ephemeralContainers?.map(y => toJson_EphemeralContainer(y)), - 'metadata': toJson_ObjectMeta(obj.metadata), + ephemeralContainers: obj.ephemeralContainers?.map((y) => + toJson_EphemeralContainer(y) + ), + metadata: toJson_ObjectMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12096,34 +13170,40 @@ export interface KubeEventProps { * @schema io.k8s.api.events.v1.Event#type */ readonly type?: string; - } /** * Converts an object of type 'KubeEventProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEventProps(obj: KubeEventProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEventProps( + obj: KubeEventProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'action': obj.action, - 'deprecatedCount': obj.deprecatedCount, - 'deprecatedFirstTimestamp': obj.deprecatedFirstTimestamp?.toISOString(), - 'deprecatedLastTimestamp': obj.deprecatedLastTimestamp?.toISOString(), - 'deprecatedSource': toJson_EventSource(obj.deprecatedSource), - 'eventTime': obj.eventTime?.toISOString(), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'note': obj.note, - 'reason': obj.reason, - 'regarding': toJson_ObjectReference(obj.regarding), - 'related': toJson_ObjectReference(obj.related), - 'reportingController': obj.reportingController, - 'reportingInstance': obj.reportingInstance, - 'series': toJson_EventSeries(obj.series), - 'type': obj.type, + action: obj.action, + deprecatedCount: obj.deprecatedCount, + deprecatedFirstTimestamp: obj.deprecatedFirstTimestamp?.toISOString(), + deprecatedLastTimestamp: obj.deprecatedLastTimestamp?.toISOString(), + deprecatedSource: toJson_EventSource(obj.deprecatedSource), + eventTime: obj.eventTime?.toISOString(), + metadata: toJson_ObjectMeta(obj.metadata), + note: obj.note, + reason: obj.reason, + regarding: toJson_ObjectReference(obj.regarding), + related: toJson_ObjectReference(obj.related), + reportingController: obj.reportingController, + reportingInstance: obj.reportingInstance, + series: toJson_EventSeries(obj.series), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12146,21 +13226,27 @@ export interface KubeEventListProps { * @schema io.k8s.api.events.v1.EventList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeEventListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEventListProps(obj: KubeEventListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEventListProps( + obj: KubeEventListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeEventProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeEventProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12183,21 +13269,27 @@ export interface KubeLimitRangeProps { * @schema io.k8s.api.core.v1.LimitRange#spec */ readonly spec?: LimitRangeSpec; - } /** * Converts an object of type 'KubeLimitRangeProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeLimitRangeProps(obj: KubeLimitRangeProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeLimitRangeProps( + obj: KubeLimitRangeProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_LimitRangeSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_LimitRangeSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12220,21 +13312,27 @@ export interface KubeLimitRangeListProps { * @schema io.k8s.api.core.v1.LimitRangeList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeLimitRangeListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeLimitRangeListProps(obj: KubeLimitRangeListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeLimitRangeListProps( + obj: KubeLimitRangeListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeLimitRangeProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeLimitRangeProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12257,21 +13355,27 @@ export interface KubeNamespaceProps { * @schema io.k8s.api.core.v1.Namespace#spec */ readonly spec?: NamespaceSpec; - } /** * Converts an object of type 'KubeNamespaceProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeNamespaceProps(obj: KubeNamespaceProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeNamespaceProps( + obj: KubeNamespaceProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_NamespaceSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_NamespaceSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12294,21 +13398,27 @@ export interface KubeNamespaceListProps { * @schema io.k8s.api.core.v1.NamespaceList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeNamespaceListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeNamespaceListProps(obj: KubeNamespaceListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeNamespaceListProps( + obj: KubeNamespaceListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeNamespaceProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeNamespaceProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12331,21 +13441,27 @@ export interface KubeNodeProps { * @schema io.k8s.api.core.v1.Node#spec */ readonly spec?: NodeSpec; - } /** * Converts an object of type 'KubeNodeProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeNodeProps(obj: KubeNodeProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeNodeProps( + obj: KubeNodeProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_NodeSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_NodeSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12368,21 +13484,27 @@ export interface KubeNodeListProps { * @schema io.k8s.api.core.v1.NodeList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeNodeListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeNodeListProps(obj: KubeNodeListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeNodeListProps( + obj: KubeNodeListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeNodeProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeNodeProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12405,21 +13527,27 @@ export interface KubePersistentVolumeProps { * @schema io.k8s.api.core.v1.PersistentVolume#spec */ readonly spec?: PersistentVolumeSpec; - } /** * Converts an object of type 'KubePersistentVolumeProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePersistentVolumeProps(obj: KubePersistentVolumeProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePersistentVolumeProps( + obj: KubePersistentVolumeProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_PersistentVolumeSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_PersistentVolumeSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12442,21 +13570,27 @@ export interface KubePersistentVolumeClaimProps { * @schema io.k8s.api.core.v1.PersistentVolumeClaim#spec */ readonly spec?: PersistentVolumeClaimSpec; - } /** * Converts an object of type 'KubePersistentVolumeClaimProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePersistentVolumeClaimProps(obj: KubePersistentVolumeClaimProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePersistentVolumeClaimProps( + obj: KubePersistentVolumeClaimProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_PersistentVolumeClaimSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_PersistentVolumeClaimSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12479,21 +13613,27 @@ export interface KubePersistentVolumeClaimListProps { * @schema io.k8s.api.core.v1.PersistentVolumeClaimList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePersistentVolumeClaimListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePersistentVolumeClaimListProps(obj: KubePersistentVolumeClaimListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePersistentVolumeClaimListProps( + obj: KubePersistentVolumeClaimListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePersistentVolumeClaimProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePersistentVolumeClaimProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12516,21 +13656,27 @@ export interface KubePersistentVolumeListProps { * @schema io.k8s.api.core.v1.PersistentVolumeList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePersistentVolumeListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePersistentVolumeListProps(obj: KubePersistentVolumeListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePersistentVolumeListProps( + obj: KubePersistentVolumeListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePersistentVolumeProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePersistentVolumeProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12553,21 +13699,27 @@ export interface KubePodProps { * @schema io.k8s.api.core.v1.Pod#spec */ readonly spec?: PodSpec; - } /** * Converts an object of type 'KubePodProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodProps(obj: KubePodProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodProps( + obj: KubePodProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_PodSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_PodSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12590,21 +13742,27 @@ export interface KubePodListProps { * @schema io.k8s.api.core.v1.PodList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePodListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodListProps(obj: KubePodListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodListProps( + obj: KubePodListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePodProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePodProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12627,21 +13785,27 @@ export interface KubePodTemplateProps { * @schema io.k8s.api.core.v1.PodTemplate#template */ readonly template?: PodTemplateSpec; - } /** * Converts an object of type 'KubePodTemplateProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodTemplateProps(obj: KubePodTemplateProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodTemplateProps( + obj: KubePodTemplateProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'template': toJson_PodTemplateSpec(obj.template), + metadata: toJson_ObjectMeta(obj.metadata), + template: toJson_PodTemplateSpec(obj.template), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12664,21 +13828,27 @@ export interface KubePodTemplateListProps { * @schema io.k8s.api.core.v1.PodTemplateList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePodTemplateListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodTemplateListProps(obj: KubePodTemplateListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodTemplateListProps( + obj: KubePodTemplateListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePodTemplateProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePodTemplateProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12701,21 +13871,27 @@ export interface KubeReplicationControllerProps { * @schema io.k8s.api.core.v1.ReplicationController#spec */ readonly spec?: ReplicationControllerSpec; - } /** * Converts an object of type 'KubeReplicationControllerProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeReplicationControllerProps(obj: KubeReplicationControllerProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeReplicationControllerProps( + obj: KubeReplicationControllerProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_ReplicationControllerSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_ReplicationControllerSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12738,21 +13914,27 @@ export interface KubeReplicationControllerListProps { * @schema io.k8s.api.core.v1.ReplicationControllerList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeReplicationControllerListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeReplicationControllerListProps(obj: KubeReplicationControllerListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeReplicationControllerListProps( + obj: KubeReplicationControllerListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeReplicationControllerProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeReplicationControllerProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12775,21 +13957,27 @@ export interface KubeResourceQuotaProps { * @schema io.k8s.api.core.v1.ResourceQuota#spec */ readonly spec?: ResourceQuotaSpec; - } /** * Converts an object of type 'KubeResourceQuotaProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeResourceQuotaProps(obj: KubeResourceQuotaProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeResourceQuotaProps( + obj: KubeResourceQuotaProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_ResourceQuotaSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_ResourceQuotaSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12812,21 +14000,27 @@ export interface KubeResourceQuotaListProps { * @schema io.k8s.api.core.v1.ResourceQuotaList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeResourceQuotaListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeResourceQuotaListProps(obj: KubeResourceQuotaListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeResourceQuotaListProps( + obj: KubeResourceQuotaListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeResourceQuotaProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeResourceQuotaProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12870,24 +14064,42 @@ export interface KubeSecretProps { * @schema io.k8s.api.core.v1.Secret#type */ readonly type?: string; - } /** * Converts an object of type 'KubeSecretProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeSecretProps(obj: KubeSecretProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeSecretProps( + obj: KubeSecretProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'data': ((obj.data) === undefined) ? undefined : (Object.entries(obj.data).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'immutable': obj.immutable, - 'metadata': toJson_ObjectMeta(obj.metadata), - 'stringData': ((obj.stringData) === undefined) ? undefined : (Object.entries(obj.stringData).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'type': obj.type, + data: + obj.data === undefined + ? undefined + : Object.entries(obj.data).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + immutable: obj.immutable, + metadata: toJson_ObjectMeta(obj.metadata), + stringData: + obj.stringData === undefined + ? undefined + : Object.entries(obj.stringData).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12910,21 +14122,27 @@ export interface KubeSecretListProps { * @schema io.k8s.api.core.v1.SecretList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeSecretListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeSecretListProps(obj: KubeSecretListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeSecretListProps( + obj: KubeSecretListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeSecretProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeSecretProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12947,21 +14165,27 @@ export interface KubeServiceProps { * @schema io.k8s.api.core.v1.Service#spec */ readonly spec?: ServiceSpec; - } /** * Converts an object of type 'KubeServiceProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeServiceProps(obj: KubeServiceProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeServiceProps( + obj: KubeServiceProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_ServiceSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_ServiceSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -12998,23 +14222,31 @@ export interface KubeServiceAccountProps { * @schema io.k8s.api.core.v1.ServiceAccount#secrets */ readonly secrets?: ObjectReference[]; - } /** * Converts an object of type 'KubeServiceAccountProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeServiceAccountProps(obj: KubeServiceAccountProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeServiceAccountProps( + obj: KubeServiceAccountProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'automountServiceAccountToken': obj.automountServiceAccountToken, - 'imagePullSecrets': obj.imagePullSecrets?.map(y => toJson_LocalObjectReference(y)), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'secrets': obj.secrets?.map(y => toJson_ObjectReference(y)), + automountServiceAccountToken: obj.automountServiceAccountToken, + imagePullSecrets: obj.imagePullSecrets?.map((y) => + toJson_LocalObjectReference(y) + ), + metadata: toJson_ObjectMeta(obj.metadata), + secrets: obj.secrets?.map((y) => toJson_ObjectReference(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13037,21 +14269,27 @@ export interface KubeServiceAccountListProps { * @schema io.k8s.api.core.v1.ServiceAccountList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeServiceAccountListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeServiceAccountListProps(obj: KubeServiceAccountListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeServiceAccountListProps( + obj: KubeServiceAccountListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeServiceAccountProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeServiceAccountProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13074,21 +14312,27 @@ export interface KubeServiceListProps { * @schema io.k8s.api.core.v1.ServiceList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeServiceListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeServiceListProps(obj: KubeServiceListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeServiceListProps( + obj: KubeServiceListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeServiceProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeServiceProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13125,23 +14369,29 @@ export interface KubeEndpointSliceProps { * @schema io.k8s.api.discovery.v1.EndpointSlice#ports */ readonly ports?: EndpointPort[]; - } /** * Converts an object of type 'KubeEndpointSliceProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEndpointSliceProps(obj: KubeEndpointSliceProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEndpointSliceProps( + obj: KubeEndpointSliceProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'addressType': obj.addressType, - 'endpoints': obj.endpoints?.map(y => toJson_Endpoint(y)), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'ports': obj.ports?.map(y => toJson_EndpointPort(y)), + addressType: obj.addressType, + endpoints: obj.endpoints?.map((y) => toJson_Endpoint(y)), + metadata: toJson_ObjectMeta(obj.metadata), + ports: obj.ports?.map((y) => toJson_EndpointPort(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13164,21 +14414,27 @@ export interface KubeEndpointSliceListProps { * @schema io.k8s.api.discovery.v1.EndpointSliceList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeEndpointSliceListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEndpointSliceListProps(obj: KubeEndpointSliceListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEndpointSliceListProps( + obj: KubeEndpointSliceListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeEndpointSliceProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeEndpointSliceProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13215,23 +14471,29 @@ export interface KubeEndpointSliceV1Beta1Props { * @schema io.k8s.api.discovery.v1beta1.EndpointSlice#ports */ readonly ports?: EndpointPortV1Beta1[]; - } /** * Converts an object of type 'KubeEndpointSliceV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEndpointSliceV1Beta1Props(obj: KubeEndpointSliceV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEndpointSliceV1Beta1Props( + obj: KubeEndpointSliceV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'addressType': obj.addressType, - 'endpoints': obj.endpoints?.map(y => toJson_EndpointV1Beta1(y)), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'ports': obj.ports?.map(y => toJson_EndpointPortV1Beta1(y)), + addressType: obj.addressType, + endpoints: obj.endpoints?.map((y) => toJson_EndpointV1Beta1(y)), + metadata: toJson_ObjectMeta(obj.metadata), + ports: obj.ports?.map((y) => toJson_EndpointPortV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13254,21 +14516,27 @@ export interface KubeEndpointSliceListV1Beta1Props { * @schema io.k8s.api.discovery.v1beta1.EndpointSliceList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeEndpointSliceListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEndpointSliceListV1Beta1Props(obj: KubeEndpointSliceListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEndpointSliceListV1Beta1Props( + obj: KubeEndpointSliceListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeEndpointSliceV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeEndpointSliceV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13382,34 +14650,40 @@ export interface KubeEventV1Beta1Props { * @schema io.k8s.api.events.v1beta1.Event#type */ readonly type?: string; - } /** * Converts an object of type 'KubeEventV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEventV1Beta1Props(obj: KubeEventV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEventV1Beta1Props( + obj: KubeEventV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'action': obj.action, - 'deprecatedCount': obj.deprecatedCount, - 'deprecatedFirstTimestamp': obj.deprecatedFirstTimestamp?.toISOString(), - 'deprecatedLastTimestamp': obj.deprecatedLastTimestamp?.toISOString(), - 'deprecatedSource': toJson_EventSource(obj.deprecatedSource), - 'eventTime': obj.eventTime?.toISOString(), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'note': obj.note, - 'reason': obj.reason, - 'regarding': toJson_ObjectReference(obj.regarding), - 'related': toJson_ObjectReference(obj.related), - 'reportingController': obj.reportingController, - 'reportingInstance': obj.reportingInstance, - 'series': toJson_EventSeriesV1Beta1(obj.series), - 'type': obj.type, + action: obj.action, + deprecatedCount: obj.deprecatedCount, + deprecatedFirstTimestamp: obj.deprecatedFirstTimestamp?.toISOString(), + deprecatedLastTimestamp: obj.deprecatedLastTimestamp?.toISOString(), + deprecatedSource: toJson_EventSource(obj.deprecatedSource), + eventTime: obj.eventTime?.toISOString(), + metadata: toJson_ObjectMeta(obj.metadata), + note: obj.note, + reason: obj.reason, + regarding: toJson_ObjectReference(obj.regarding), + related: toJson_ObjectReference(obj.related), + reportingController: obj.reportingController, + reportingInstance: obj.reportingInstance, + series: toJson_EventSeriesV1Beta1(obj.series), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13432,21 +14706,27 @@ export interface KubeEventListV1Beta1Props { * @schema io.k8s.api.events.v1beta1.EventList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeEventListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEventListV1Beta1Props(obj: KubeEventListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEventListV1Beta1Props( + obj: KubeEventListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeEventV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeEventV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13469,21 +14749,27 @@ export interface KubeIngressV1Beta1Props { * @schema io.k8s.api.networking.v1beta1.Ingress#spec */ readonly spec?: IngressSpecV1Beta1; - } /** * Converts an object of type 'KubeIngressV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeIngressV1Beta1Props(obj: KubeIngressV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeIngressV1Beta1Props( + obj: KubeIngressV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_IngressSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_IngressSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13506,21 +14792,27 @@ export interface KubeIngressListV1Beta1Props { * @schema io.k8s.api.networking.v1beta1.IngressList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeIngressListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeIngressListV1Beta1Props(obj: KubeIngressListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeIngressListV1Beta1Props( + obj: KubeIngressListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeIngressV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeIngressV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13543,21 +14835,27 @@ export interface KubeFlowSchemaV1Beta1Props { * @schema io.k8s.api.flowcontrol.v1beta1.FlowSchema#spec */ readonly spec?: FlowSchemaSpecV1Beta1; - } /** * Converts an object of type 'KubeFlowSchemaV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeFlowSchemaV1Beta1Props(obj: KubeFlowSchemaV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeFlowSchemaV1Beta1Props( + obj: KubeFlowSchemaV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_FlowSchemaSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_FlowSchemaSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13580,21 +14878,27 @@ export interface KubeFlowSchemaListV1Beta1Props { * @schema io.k8s.api.flowcontrol.v1beta1.FlowSchemaList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeFlowSchemaListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeFlowSchemaListV1Beta1Props(obj: KubeFlowSchemaListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeFlowSchemaListV1Beta1Props( + obj: KubeFlowSchemaListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeFlowSchemaV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeFlowSchemaV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13617,21 +14921,27 @@ export interface KubePriorityLevelConfigurationV1Beta1Props { * @schema io.k8s.api.flowcontrol.v1beta1.PriorityLevelConfiguration#spec */ readonly spec?: PriorityLevelConfigurationSpecV1Beta1; - } /** * Converts an object of type 'KubePriorityLevelConfigurationV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePriorityLevelConfigurationV1Beta1Props(obj: KubePriorityLevelConfigurationV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePriorityLevelConfigurationV1Beta1Props( + obj: KubePriorityLevelConfigurationV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_PriorityLevelConfigurationSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_PriorityLevelConfigurationSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13654,21 +14964,29 @@ export interface KubePriorityLevelConfigurationListV1Beta1Props { * @schema io.k8s.api.flowcontrol.v1beta1.PriorityLevelConfigurationList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePriorityLevelConfigurationListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePriorityLevelConfigurationListV1Beta1Props(obj: KubePriorityLevelConfigurationListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePriorityLevelConfigurationListV1Beta1Props( + obj: KubePriorityLevelConfigurationListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePriorityLevelConfigurationV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => + toJson_KubePriorityLevelConfigurationV1Beta1Props(y) + ), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13691,21 +15009,27 @@ export interface KubeIngressProps { * @schema io.k8s.api.networking.v1.Ingress#spec */ readonly spec?: IngressSpec; - } /** * Converts an object of type 'KubeIngressProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeIngressProps(obj: KubeIngressProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeIngressProps( + obj: KubeIngressProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_IngressSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_IngressSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13728,21 +15052,27 @@ export interface KubeIngressClassProps { * @schema io.k8s.api.networking.v1.IngressClass#spec */ readonly spec?: IngressClassSpec; - } /** * Converts an object of type 'KubeIngressClassProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeIngressClassProps(obj: KubeIngressClassProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeIngressClassProps( + obj: KubeIngressClassProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_IngressClassSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_IngressClassSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13765,21 +15095,27 @@ export interface KubeIngressClassListProps { * @schema io.k8s.api.networking.v1.IngressClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeIngressClassListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeIngressClassListProps(obj: KubeIngressClassListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeIngressClassListProps( + obj: KubeIngressClassListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeIngressClassProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeIngressClassProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13802,21 +15138,27 @@ export interface KubeIngressListProps { * @schema io.k8s.api.networking.v1.IngressList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeIngressListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeIngressListProps(obj: KubeIngressListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeIngressListProps( + obj: KubeIngressListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeIngressProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeIngressProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13839,21 +15181,27 @@ export interface KubeNetworkPolicyProps { * @schema io.k8s.api.networking.v1.NetworkPolicy#spec */ readonly spec?: NetworkPolicySpec; - } /** * Converts an object of type 'KubeNetworkPolicyProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeNetworkPolicyProps(obj: KubeNetworkPolicyProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeNetworkPolicyProps( + obj: KubeNetworkPolicyProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_NetworkPolicySpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_NetworkPolicySpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13876,21 +15224,27 @@ export interface KubeNetworkPolicyListProps { * @schema io.k8s.api.networking.v1.NetworkPolicyList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeNetworkPolicyListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeNetworkPolicyListProps(obj: KubeNetworkPolicyListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeNetworkPolicyListProps( + obj: KubeNetworkPolicyListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeNetworkPolicyProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeNetworkPolicyProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13913,21 +15267,27 @@ export interface KubeIngressClassV1Beta1Props { * @schema io.k8s.api.networking.v1beta1.IngressClass#spec */ readonly spec?: IngressClassSpecV1Beta1; - } /** * Converts an object of type 'KubeIngressClassV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeIngressClassV1Beta1Props(obj: KubeIngressClassV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeIngressClassV1Beta1Props( + obj: KubeIngressClassV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_IngressClassSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_IngressClassSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -13950,21 +15310,27 @@ export interface KubeIngressClassListV1Beta1Props { * @schema io.k8s.api.networking.v1beta1.IngressClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeIngressClassListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeIngressClassListV1Beta1Props(obj: KubeIngressClassListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeIngressClassListV1Beta1Props( + obj: KubeIngressClassListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeIngressClassV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeIngressClassV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14003,23 +15369,29 @@ export interface KubeRuntimeClassProps { * @schema io.k8s.api.node.v1.RuntimeClass#scheduling */ readonly scheduling?: Scheduling; - } /** * Converts an object of type 'KubeRuntimeClassProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRuntimeClassProps(obj: KubeRuntimeClassProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRuntimeClassProps( + obj: KubeRuntimeClassProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'handler': obj.handler, - 'metadata': toJson_ObjectMeta(obj.metadata), - 'overhead': toJson_Overhead(obj.overhead), - 'scheduling': toJson_Scheduling(obj.scheduling), + handler: obj.handler, + metadata: toJson_ObjectMeta(obj.metadata), + overhead: toJson_Overhead(obj.overhead), + scheduling: toJson_Scheduling(obj.scheduling), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14042,21 +15414,27 @@ export interface KubeRuntimeClassListProps { * @schema io.k8s.api.node.v1.RuntimeClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeRuntimeClassListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRuntimeClassListProps(obj: KubeRuntimeClassListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRuntimeClassListProps( + obj: KubeRuntimeClassListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeRuntimeClassProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeRuntimeClassProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14079,21 +15457,27 @@ export interface KubeRuntimeClassV1Alpha1Props { * @schema io.k8s.api.node.v1alpha1.RuntimeClass#spec */ readonly spec: RuntimeClassSpecV1Alpha1; - } /** * Converts an object of type 'KubeRuntimeClassV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRuntimeClassV1Alpha1Props(obj: KubeRuntimeClassV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRuntimeClassV1Alpha1Props( + obj: KubeRuntimeClassV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_RuntimeClassSpecV1Alpha1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_RuntimeClassSpecV1Alpha1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14116,21 +15500,27 @@ export interface KubeRuntimeClassListV1Alpha1Props { * @schema io.k8s.api.node.v1alpha1.RuntimeClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeRuntimeClassListV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRuntimeClassListV1Alpha1Props(obj: KubeRuntimeClassListV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRuntimeClassListV1Alpha1Props( + obj: KubeRuntimeClassListV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeRuntimeClassV1Alpha1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeRuntimeClassV1Alpha1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14167,23 +15557,29 @@ export interface KubeRuntimeClassV1Beta1Props { * @schema io.k8s.api.node.v1beta1.RuntimeClass#scheduling */ readonly scheduling?: SchedulingV1Beta1; - } /** * Converts an object of type 'KubeRuntimeClassV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRuntimeClassV1Beta1Props(obj: KubeRuntimeClassV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRuntimeClassV1Beta1Props( + obj: KubeRuntimeClassV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'handler': obj.handler, - 'metadata': toJson_ObjectMeta(obj.metadata), - 'overhead': toJson_OverheadV1Beta1(obj.overhead), - 'scheduling': toJson_SchedulingV1Beta1(obj.scheduling), + handler: obj.handler, + metadata: toJson_ObjectMeta(obj.metadata), + overhead: toJson_OverheadV1Beta1(obj.overhead), + scheduling: toJson_SchedulingV1Beta1(obj.scheduling), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14206,21 +15602,27 @@ export interface KubeRuntimeClassListV1Beta1Props { * @schema io.k8s.api.node.v1beta1.RuntimeClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeRuntimeClassListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRuntimeClassListV1Beta1Props(obj: KubeRuntimeClassListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRuntimeClassListV1Beta1Props( + obj: KubeRuntimeClassListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeRuntimeClassV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeRuntimeClassV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14243,21 +15645,27 @@ export interface KubePodDisruptionBudgetProps { * @schema io.k8s.api.policy.v1.PodDisruptionBudget#spec */ readonly spec?: PodDisruptionBudgetSpec; - } /** * Converts an object of type 'KubePodDisruptionBudgetProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodDisruptionBudgetProps(obj: KubePodDisruptionBudgetProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodDisruptionBudgetProps( + obj: KubePodDisruptionBudgetProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_PodDisruptionBudgetSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_PodDisruptionBudgetSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14280,21 +15688,27 @@ export interface KubePodDisruptionBudgetListProps { * @schema io.k8s.api.policy.v1.PodDisruptionBudgetList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePodDisruptionBudgetListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodDisruptionBudgetListProps(obj: KubePodDisruptionBudgetListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodDisruptionBudgetListProps( + obj: KubePodDisruptionBudgetListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePodDisruptionBudgetProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePodDisruptionBudgetProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14317,21 +15731,27 @@ export interface KubeEvictionV1Beta1Props { * @schema io.k8s.api.policy.v1beta1.Eviction#metadata */ readonly metadata?: ObjectMeta; - } /** * Converts an object of type 'KubeEvictionV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeEvictionV1Beta1Props(obj: KubeEvictionV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeEvictionV1Beta1Props( + obj: KubeEvictionV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'deleteOptions': toJson_DeleteOptions(obj.deleteOptions), - 'metadata': toJson_ObjectMeta(obj.metadata), + deleteOptions: toJson_DeleteOptions(obj.deleteOptions), + metadata: toJson_ObjectMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14352,21 +15772,27 @@ export interface KubePodDisruptionBudgetV1Beta1Props { * @schema io.k8s.api.policy.v1beta1.PodDisruptionBudget#spec */ readonly spec?: PodDisruptionBudgetSpecV1Beta1; - } /** * Converts an object of type 'KubePodDisruptionBudgetV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodDisruptionBudgetV1Beta1Props(obj: KubePodDisruptionBudgetV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodDisruptionBudgetV1Beta1Props( + obj: KubePodDisruptionBudgetV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_PodDisruptionBudgetSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_PodDisruptionBudgetSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14385,21 +15811,27 @@ export interface KubePodDisruptionBudgetListV1Beta1Props { * @schema io.k8s.api.policy.v1beta1.PodDisruptionBudgetList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePodDisruptionBudgetListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodDisruptionBudgetListV1Beta1Props(obj: KubePodDisruptionBudgetListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodDisruptionBudgetListV1Beta1Props( + obj: KubePodDisruptionBudgetListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePodDisruptionBudgetV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePodDisruptionBudgetV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14422,21 +15854,27 @@ export interface KubePodSecurityPolicyV1Beta1Props { * @schema io.k8s.api.policy.v1beta1.PodSecurityPolicy#spec */ readonly spec?: PodSecurityPolicySpecV1Beta1; - } /** * Converts an object of type 'KubePodSecurityPolicyV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodSecurityPolicyV1Beta1Props(obj: KubePodSecurityPolicyV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodSecurityPolicyV1Beta1Props( + obj: KubePodSecurityPolicyV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_PodSecurityPolicySpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_PodSecurityPolicySpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14459,21 +15897,27 @@ export interface KubePodSecurityPolicyListV1Beta1Props { * @schema io.k8s.api.policy.v1beta1.PodSecurityPolicyList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePodSecurityPolicyListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePodSecurityPolicyListV1Beta1Props(obj: KubePodSecurityPolicyListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePodSecurityPolicyListV1Beta1Props( + obj: KubePodSecurityPolicyListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePodSecurityPolicyV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePodSecurityPolicyV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14503,22 +15947,28 @@ export interface KubeClusterRoleProps { * @schema io.k8s.api.rbac.v1.ClusterRole#rules */ readonly rules?: PolicyRule[]; - } /** * Converts an object of type 'KubeClusterRoleProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleProps(obj: KubeClusterRoleProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleProps( + obj: KubeClusterRoleProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'aggregationRule': toJson_AggregationRule(obj.aggregationRule), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'rules': obj.rules?.map(y => toJson_PolicyRule(y)), + aggregationRule: toJson_AggregationRule(obj.aggregationRule), + metadata: toJson_ObjectMeta(obj.metadata), + rules: obj.rules?.map((y) => toJson_PolicyRule(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14548,22 +15998,28 @@ export interface KubeClusterRoleBindingProps { * @schema io.k8s.api.rbac.v1.ClusterRoleBinding#subjects */ readonly subjects?: Subject[]; - } /** * Converts an object of type 'KubeClusterRoleBindingProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleBindingProps(obj: KubeClusterRoleBindingProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleBindingProps( + obj: KubeClusterRoleBindingProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'roleRef': toJson_RoleRef(obj.roleRef), - 'subjects': obj.subjects?.map(y => toJson_Subject(y)), + metadata: toJson_ObjectMeta(obj.metadata), + roleRef: toJson_RoleRef(obj.roleRef), + subjects: obj.subjects?.map((y) => toJson_Subject(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14586,21 +16042,27 @@ export interface KubeClusterRoleBindingListProps { * @schema io.k8s.api.rbac.v1.ClusterRoleBindingList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeClusterRoleBindingListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleBindingListProps(obj: KubeClusterRoleBindingListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleBindingListProps( + obj: KubeClusterRoleBindingListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeClusterRoleBindingProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeClusterRoleBindingProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14623,21 +16085,27 @@ export interface KubeClusterRoleListProps { * @schema io.k8s.api.rbac.v1.ClusterRoleList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeClusterRoleListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleListProps(obj: KubeClusterRoleListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleListProps( + obj: KubeClusterRoleListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeClusterRoleProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeClusterRoleProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14660,21 +16128,27 @@ export interface KubeRoleProps { * @schema io.k8s.api.rbac.v1.Role#rules */ readonly rules?: PolicyRule[]; - } /** * Converts an object of type 'KubeRoleProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleProps(obj: KubeRoleProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleProps( + obj: KubeRoleProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'rules': obj.rules?.map(y => toJson_PolicyRule(y)), + metadata: toJson_ObjectMeta(obj.metadata), + rules: obj.rules?.map((y) => toJson_PolicyRule(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14704,22 +16178,28 @@ export interface KubeRoleBindingProps { * @schema io.k8s.api.rbac.v1.RoleBinding#subjects */ readonly subjects?: Subject[]; - } /** * Converts an object of type 'KubeRoleBindingProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleBindingProps(obj: KubeRoleBindingProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleBindingProps( + obj: KubeRoleBindingProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'roleRef': toJson_RoleRef(obj.roleRef), - 'subjects': obj.subjects?.map(y => toJson_Subject(y)), + metadata: toJson_ObjectMeta(obj.metadata), + roleRef: toJson_RoleRef(obj.roleRef), + subjects: obj.subjects?.map((y) => toJson_Subject(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14742,21 +16222,27 @@ export interface KubeRoleBindingListProps { * @schema io.k8s.api.rbac.v1.RoleBindingList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeRoleBindingListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleBindingListProps(obj: KubeRoleBindingListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleBindingListProps( + obj: KubeRoleBindingListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeRoleBindingProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeRoleBindingProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14779,21 +16265,27 @@ export interface KubeRoleListProps { * @schema io.k8s.api.rbac.v1.RoleList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeRoleListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleListProps(obj: KubeRoleListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleListProps( + obj: KubeRoleListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeRoleProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeRoleProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14823,22 +16315,28 @@ export interface KubeClusterRoleV1Alpha1Props { * @schema io.k8s.api.rbac.v1alpha1.ClusterRole#rules */ readonly rules?: PolicyRuleV1Alpha1[]; - } /** * Converts an object of type 'KubeClusterRoleV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleV1Alpha1Props(obj: KubeClusterRoleV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleV1Alpha1Props( + obj: KubeClusterRoleV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'aggregationRule': toJson_AggregationRuleV1Alpha1(obj.aggregationRule), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'rules': obj.rules?.map(y => toJson_PolicyRuleV1Alpha1(y)), + aggregationRule: toJson_AggregationRuleV1Alpha1(obj.aggregationRule), + metadata: toJson_ObjectMeta(obj.metadata), + rules: obj.rules?.map((y) => toJson_PolicyRuleV1Alpha1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14868,22 +16366,28 @@ export interface KubeClusterRoleBindingV1Alpha1Props { * @schema io.k8s.api.rbac.v1alpha1.ClusterRoleBinding#subjects */ readonly subjects?: SubjectV1Alpha1[]; - } /** * Converts an object of type 'KubeClusterRoleBindingV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleBindingV1Alpha1Props(obj: KubeClusterRoleBindingV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleBindingV1Alpha1Props( + obj: KubeClusterRoleBindingV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'roleRef': toJson_RoleRefV1Alpha1(obj.roleRef), - 'subjects': obj.subjects?.map(y => toJson_SubjectV1Alpha1(y)), + metadata: toJson_ObjectMeta(obj.metadata), + roleRef: toJson_RoleRefV1Alpha1(obj.roleRef), + subjects: obj.subjects?.map((y) => toJson_SubjectV1Alpha1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14906,21 +16410,27 @@ export interface KubeClusterRoleBindingListV1Alpha1Props { * @schema io.k8s.api.rbac.v1alpha1.ClusterRoleBindingList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeClusterRoleBindingListV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleBindingListV1Alpha1Props(obj: KubeClusterRoleBindingListV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleBindingListV1Alpha1Props( + obj: KubeClusterRoleBindingListV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeClusterRoleBindingV1Alpha1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeClusterRoleBindingV1Alpha1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14943,21 +16453,27 @@ export interface KubeClusterRoleListV1Alpha1Props { * @schema io.k8s.api.rbac.v1alpha1.ClusterRoleList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeClusterRoleListV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleListV1Alpha1Props(obj: KubeClusterRoleListV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleListV1Alpha1Props( + obj: KubeClusterRoleListV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeClusterRoleV1Alpha1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeClusterRoleV1Alpha1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -14980,21 +16496,27 @@ export interface KubeRoleV1Alpha1Props { * @schema io.k8s.api.rbac.v1alpha1.Role#rules */ readonly rules?: PolicyRuleV1Alpha1[]; - } /** * Converts an object of type 'KubeRoleV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleV1Alpha1Props(obj: KubeRoleV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleV1Alpha1Props( + obj: KubeRoleV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'rules': obj.rules?.map(y => toJson_PolicyRuleV1Alpha1(y)), + metadata: toJson_ObjectMeta(obj.metadata), + rules: obj.rules?.map((y) => toJson_PolicyRuleV1Alpha1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15024,22 +16546,28 @@ export interface KubeRoleBindingV1Alpha1Props { * @schema io.k8s.api.rbac.v1alpha1.RoleBinding#subjects */ readonly subjects?: SubjectV1Alpha1[]; - } /** * Converts an object of type 'KubeRoleBindingV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleBindingV1Alpha1Props(obj: KubeRoleBindingV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleBindingV1Alpha1Props( + obj: KubeRoleBindingV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'roleRef': toJson_RoleRefV1Alpha1(obj.roleRef), - 'subjects': obj.subjects?.map(y => toJson_SubjectV1Alpha1(y)), + metadata: toJson_ObjectMeta(obj.metadata), + roleRef: toJson_RoleRefV1Alpha1(obj.roleRef), + subjects: obj.subjects?.map((y) => toJson_SubjectV1Alpha1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15062,21 +16590,27 @@ export interface KubeRoleBindingListV1Alpha1Props { * @schema io.k8s.api.rbac.v1alpha1.RoleBindingList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeRoleBindingListV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleBindingListV1Alpha1Props(obj: KubeRoleBindingListV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleBindingListV1Alpha1Props( + obj: KubeRoleBindingListV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeRoleBindingV1Alpha1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeRoleBindingV1Alpha1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15099,21 +16633,27 @@ export interface KubeRoleListV1Alpha1Props { * @schema io.k8s.api.rbac.v1alpha1.RoleList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeRoleListV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleListV1Alpha1Props(obj: KubeRoleListV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleListV1Alpha1Props( + obj: KubeRoleListV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeRoleV1Alpha1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeRoleV1Alpha1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15143,22 +16683,28 @@ export interface KubeClusterRoleV1Beta1Props { * @schema io.k8s.api.rbac.v1beta1.ClusterRole#rules */ readonly rules?: PolicyRuleV1Beta1[]; - } /** * Converts an object of type 'KubeClusterRoleV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleV1Beta1Props(obj: KubeClusterRoleV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleV1Beta1Props( + obj: KubeClusterRoleV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'aggregationRule': toJson_AggregationRuleV1Beta1(obj.aggregationRule), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'rules': obj.rules?.map(y => toJson_PolicyRuleV1Beta1(y)), + aggregationRule: toJson_AggregationRuleV1Beta1(obj.aggregationRule), + metadata: toJson_ObjectMeta(obj.metadata), + rules: obj.rules?.map((y) => toJson_PolicyRuleV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15188,22 +16734,28 @@ export interface KubeClusterRoleBindingV1Beta1Props { * @schema io.k8s.api.rbac.v1beta1.ClusterRoleBinding#subjects */ readonly subjects?: SubjectV1Beta1[]; - } /** * Converts an object of type 'KubeClusterRoleBindingV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleBindingV1Beta1Props(obj: KubeClusterRoleBindingV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleBindingV1Beta1Props( + obj: KubeClusterRoleBindingV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'roleRef': toJson_RoleRefV1Beta1(obj.roleRef), - 'subjects': obj.subjects?.map(y => toJson_SubjectV1Beta1(y)), + metadata: toJson_ObjectMeta(obj.metadata), + roleRef: toJson_RoleRefV1Beta1(obj.roleRef), + subjects: obj.subjects?.map((y) => toJson_SubjectV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15226,21 +16778,27 @@ export interface KubeClusterRoleBindingListV1Beta1Props { * @schema io.k8s.api.rbac.v1beta1.ClusterRoleBindingList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeClusterRoleBindingListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleBindingListV1Beta1Props(obj: KubeClusterRoleBindingListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleBindingListV1Beta1Props( + obj: KubeClusterRoleBindingListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeClusterRoleBindingV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeClusterRoleBindingV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15263,21 +16821,27 @@ export interface KubeClusterRoleListV1Beta1Props { * @schema io.k8s.api.rbac.v1beta1.ClusterRoleList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeClusterRoleListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeClusterRoleListV1Beta1Props(obj: KubeClusterRoleListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeClusterRoleListV1Beta1Props( + obj: KubeClusterRoleListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeClusterRoleV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeClusterRoleV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15300,21 +16864,27 @@ export interface KubeRoleV1Beta1Props { * @schema io.k8s.api.rbac.v1beta1.Role#rules */ readonly rules?: PolicyRuleV1Beta1[]; - } /** * Converts an object of type 'KubeRoleV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleV1Beta1Props(obj: KubeRoleV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleV1Beta1Props( + obj: KubeRoleV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'rules': obj.rules?.map(y => toJson_PolicyRuleV1Beta1(y)), + metadata: toJson_ObjectMeta(obj.metadata), + rules: obj.rules?.map((y) => toJson_PolicyRuleV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15344,22 +16914,28 @@ export interface KubeRoleBindingV1Beta1Props { * @schema io.k8s.api.rbac.v1beta1.RoleBinding#subjects */ readonly subjects?: SubjectV1Beta1[]; - } /** * Converts an object of type 'KubeRoleBindingV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleBindingV1Beta1Props(obj: KubeRoleBindingV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleBindingV1Beta1Props( + obj: KubeRoleBindingV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'roleRef': toJson_RoleRefV1Beta1(obj.roleRef), - 'subjects': obj.subjects?.map(y => toJson_SubjectV1Beta1(y)), + metadata: toJson_ObjectMeta(obj.metadata), + roleRef: toJson_RoleRefV1Beta1(obj.roleRef), + subjects: obj.subjects?.map((y) => toJson_SubjectV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15382,21 +16958,27 @@ export interface KubeRoleBindingListV1Beta1Props { * @schema io.k8s.api.rbac.v1beta1.RoleBindingList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeRoleBindingListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleBindingListV1Beta1Props(obj: KubeRoleBindingListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleBindingListV1Beta1Props( + obj: KubeRoleBindingListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeRoleBindingV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeRoleBindingV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15419,21 +17001,27 @@ export interface KubeRoleListV1Beta1Props { * @schema io.k8s.api.rbac.v1beta1.RoleList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeRoleListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeRoleListV1Beta1Props(obj: KubeRoleListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeRoleListV1Beta1Props( + obj: KubeRoleListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeRoleV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeRoleV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15478,24 +17066,30 @@ export interface KubePriorityClassProps { * @schema io.k8s.api.scheduling.v1.PriorityClass#value */ readonly value: number; - } /** * Converts an object of type 'KubePriorityClassProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePriorityClassProps(obj: KubePriorityClassProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePriorityClassProps( + obj: KubePriorityClassProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'description': obj.description, - 'globalDefault': obj.globalDefault, - 'metadata': toJson_ObjectMeta(obj.metadata), - 'preemptionPolicy': obj.preemptionPolicy, - 'value': obj.value, + description: obj.description, + globalDefault: obj.globalDefault, + metadata: toJson_ObjectMeta(obj.metadata), + preemptionPolicy: obj.preemptionPolicy, + value: obj.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15518,21 +17112,27 @@ export interface KubePriorityClassListProps { * @schema io.k8s.api.scheduling.v1.PriorityClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePriorityClassListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePriorityClassListProps(obj: KubePriorityClassListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePriorityClassListProps( + obj: KubePriorityClassListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePriorityClassProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePriorityClassProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15577,24 +17177,30 @@ export interface KubePriorityClassV1Alpha1Props { * @schema io.k8s.api.scheduling.v1alpha1.PriorityClass#value */ readonly value: number; - } /** * Converts an object of type 'KubePriorityClassV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePriorityClassV1Alpha1Props(obj: KubePriorityClassV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePriorityClassV1Alpha1Props( + obj: KubePriorityClassV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'description': obj.description, - 'globalDefault': obj.globalDefault, - 'metadata': toJson_ObjectMeta(obj.metadata), - 'preemptionPolicy': obj.preemptionPolicy, - 'value': obj.value, + description: obj.description, + globalDefault: obj.globalDefault, + metadata: toJson_ObjectMeta(obj.metadata), + preemptionPolicy: obj.preemptionPolicy, + value: obj.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15617,21 +17223,27 @@ export interface KubePriorityClassListV1Alpha1Props { * @schema io.k8s.api.scheduling.v1alpha1.PriorityClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePriorityClassListV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePriorityClassListV1Alpha1Props(obj: KubePriorityClassListV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePriorityClassListV1Alpha1Props( + obj: KubePriorityClassListV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePriorityClassV1Alpha1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePriorityClassV1Alpha1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15676,24 +17288,30 @@ export interface KubePriorityClassV1Beta1Props { * @schema io.k8s.api.scheduling.v1beta1.PriorityClass#value */ readonly value: number; - } /** * Converts an object of type 'KubePriorityClassV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePriorityClassV1Beta1Props(obj: KubePriorityClassV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePriorityClassV1Beta1Props( + obj: KubePriorityClassV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'description': obj.description, - 'globalDefault': obj.globalDefault, - 'metadata': toJson_ObjectMeta(obj.metadata), - 'preemptionPolicy': obj.preemptionPolicy, - 'value': obj.value, + description: obj.description, + globalDefault: obj.globalDefault, + metadata: toJson_ObjectMeta(obj.metadata), + preemptionPolicy: obj.preemptionPolicy, + value: obj.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15716,21 +17334,27 @@ export interface KubePriorityClassListV1Beta1Props { * @schema io.k8s.api.scheduling.v1beta1.PriorityClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubePriorityClassListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubePriorityClassListV1Beta1Props(obj: KubePriorityClassListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubePriorityClassListV1Beta1Props( + obj: KubePriorityClassListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubePriorityClassV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubePriorityClassV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15753,21 +17377,27 @@ export interface KubeCsiDriverProps { * @schema io.k8s.api.storage.v1.CSIDriver#spec */ readonly spec: CsiDriverSpec; - } /** * Converts an object of type 'KubeCsiDriverProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiDriverProps(obj: KubeCsiDriverProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiDriverProps( + obj: KubeCsiDriverProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CsiDriverSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CsiDriverSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15790,21 +17420,27 @@ export interface KubeCsiDriverListProps { * @schema io.k8s.api.storage.v1.CSIDriverList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCsiDriverListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiDriverListProps(obj: KubeCsiDriverListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiDriverListProps( + obj: KubeCsiDriverListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCsiDriverProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCsiDriverProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15827,21 +17463,27 @@ export interface KubeCsiNodeProps { * @schema io.k8s.api.storage.v1.CSINode#spec */ readonly spec: CsiNodeSpec; - } /** * Converts an object of type 'KubeCsiNodeProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiNodeProps(obj: KubeCsiNodeProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiNodeProps( + obj: KubeCsiNodeProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CsiNodeSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CsiNodeSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15864,21 +17506,27 @@ export interface KubeCsiNodeListProps { * @schema io.k8s.api.storage.v1.CSINodeList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCsiNodeListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiNodeListProps(obj: KubeCsiNodeListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiNodeListProps( + obj: KubeCsiNodeListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCsiNodeProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCsiNodeProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15946,27 +17594,41 @@ export interface KubeStorageClassProps { * @schema io.k8s.api.storage.v1.StorageClass#volumeBindingMode */ readonly volumeBindingMode?: string; - } /** * Converts an object of type 'KubeStorageClassProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeStorageClassProps(obj: KubeStorageClassProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeStorageClassProps( + obj: KubeStorageClassProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'allowVolumeExpansion': obj.allowVolumeExpansion, - 'allowedTopologies': obj.allowedTopologies?.map(y => toJson_TopologySelectorTerm(y)), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'mountOptions': obj.mountOptions?.map(y => y), - 'parameters': ((obj.parameters) === undefined) ? undefined : (Object.entries(obj.parameters).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'provisioner': obj.provisioner, - 'reclaimPolicy': obj.reclaimPolicy, - 'volumeBindingMode': obj.volumeBindingMode, + allowVolumeExpansion: obj.allowVolumeExpansion, + allowedTopologies: obj.allowedTopologies?.map((y) => + toJson_TopologySelectorTerm(y) + ), + metadata: toJson_ObjectMeta(obj.metadata), + mountOptions: obj.mountOptions?.map((y) => y), + parameters: + obj.parameters === undefined + ? undefined + : Object.entries(obj.parameters).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + provisioner: obj.provisioner, + reclaimPolicy: obj.reclaimPolicy, + volumeBindingMode: obj.volumeBindingMode, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -15989,21 +17651,27 @@ export interface KubeStorageClassListProps { * @schema io.k8s.api.storage.v1.StorageClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeStorageClassListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeStorageClassListProps(obj: KubeStorageClassListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeStorageClassListProps( + obj: KubeStorageClassListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeStorageClassProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeStorageClassProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16028,21 +17696,27 @@ export interface KubeVolumeAttachmentProps { * @schema io.k8s.api.storage.v1.VolumeAttachment#spec */ readonly spec: VolumeAttachmentSpec; - } /** * Converts an object of type 'KubeVolumeAttachmentProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeVolumeAttachmentProps(obj: KubeVolumeAttachmentProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeVolumeAttachmentProps( + obj: KubeVolumeAttachmentProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_VolumeAttachmentSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_VolumeAttachmentSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16065,21 +17739,27 @@ export interface KubeVolumeAttachmentListProps { * @schema io.k8s.api.storage.v1.VolumeAttachmentList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeVolumeAttachmentListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeVolumeAttachmentListProps(obj: KubeVolumeAttachmentListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeVolumeAttachmentListProps( + obj: KubeVolumeAttachmentListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeVolumeAttachmentProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeVolumeAttachmentProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16139,24 +17819,30 @@ export interface KubeCsiStorageCapacityV1Alpha1Props { * @schema io.k8s.api.storage.v1alpha1.CSIStorageCapacity#storageClassName */ readonly storageClassName: string; - } /** * Converts an object of type 'KubeCsiStorageCapacityV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiStorageCapacityV1Alpha1Props(obj: KubeCsiStorageCapacityV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiStorageCapacityV1Alpha1Props( + obj: KubeCsiStorageCapacityV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'capacity': obj.capacity?.value, - 'maximumVolumeSize': obj.maximumVolumeSize?.value, - 'metadata': toJson_ObjectMeta(obj.metadata), - 'nodeTopology': toJson_LabelSelector(obj.nodeTopology), - 'storageClassName': obj.storageClassName, + capacity: obj.capacity?.value, + maximumVolumeSize: obj.maximumVolumeSize?.value, + metadata: toJson_ObjectMeta(obj.metadata), + nodeTopology: toJson_LabelSelector(obj.nodeTopology), + storageClassName: obj.storageClassName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16179,21 +17865,27 @@ export interface KubeCsiStorageCapacityListV1Alpha1Props { * @schema io.k8s.api.storage.v1alpha1.CSIStorageCapacityList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCsiStorageCapacityListV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiStorageCapacityListV1Alpha1Props(obj: KubeCsiStorageCapacityListV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiStorageCapacityListV1Alpha1Props( + obj: KubeCsiStorageCapacityListV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCsiStorageCapacityV1Alpha1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCsiStorageCapacityV1Alpha1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16218,21 +17910,27 @@ export interface KubeVolumeAttachmentV1Alpha1Props { * @schema io.k8s.api.storage.v1alpha1.VolumeAttachment#spec */ readonly spec: VolumeAttachmentSpecV1Alpha1; - } /** * Converts an object of type 'KubeVolumeAttachmentV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeVolumeAttachmentV1Alpha1Props(obj: KubeVolumeAttachmentV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeVolumeAttachmentV1Alpha1Props( + obj: KubeVolumeAttachmentV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_VolumeAttachmentSpecV1Alpha1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_VolumeAttachmentSpecV1Alpha1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16255,21 +17953,27 @@ export interface KubeVolumeAttachmentListV1Alpha1Props { * @schema io.k8s.api.storage.v1alpha1.VolumeAttachmentList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeVolumeAttachmentListV1Alpha1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeVolumeAttachmentListV1Alpha1Props(obj: KubeVolumeAttachmentListV1Alpha1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeVolumeAttachmentListV1Alpha1Props( + obj: KubeVolumeAttachmentListV1Alpha1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeVolumeAttachmentV1Alpha1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeVolumeAttachmentV1Alpha1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16292,21 +17996,27 @@ export interface KubeCsiDriverV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.CSIDriver#spec */ readonly spec: CsiDriverSpecV1Beta1; - } /** * Converts an object of type 'KubeCsiDriverV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiDriverV1Beta1Props(obj: KubeCsiDriverV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiDriverV1Beta1Props( + obj: KubeCsiDriverV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CsiDriverSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CsiDriverSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16329,21 +18039,27 @@ export interface KubeCsiDriverListV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.CSIDriverList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCsiDriverListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiDriverListV1Beta1Props(obj: KubeCsiDriverListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiDriverListV1Beta1Props( + obj: KubeCsiDriverListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCsiDriverV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCsiDriverV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16366,21 +18082,27 @@ export interface KubeCsiNodeV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.CSINode#spec */ readonly spec: CsiNodeSpecV1Beta1; - } /** * Converts an object of type 'KubeCsiNodeV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiNodeV1Beta1Props(obj: KubeCsiNodeV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiNodeV1Beta1Props( + obj: KubeCsiNodeV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CsiNodeSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CsiNodeSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16403,21 +18125,27 @@ export interface KubeCsiNodeListV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.CSINodeList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCsiNodeListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiNodeListV1Beta1Props(obj: KubeCsiNodeListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiNodeListV1Beta1Props( + obj: KubeCsiNodeListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCsiNodeV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCsiNodeV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16477,24 +18205,30 @@ export interface KubeCsiStorageCapacityV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.CSIStorageCapacity#storageClassName */ readonly storageClassName: string; - } /** * Converts an object of type 'KubeCsiStorageCapacityV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiStorageCapacityV1Beta1Props(obj: KubeCsiStorageCapacityV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiStorageCapacityV1Beta1Props( + obj: KubeCsiStorageCapacityV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'capacity': obj.capacity?.value, - 'maximumVolumeSize': obj.maximumVolumeSize?.value, - 'metadata': toJson_ObjectMeta(obj.metadata), - 'nodeTopology': toJson_LabelSelector(obj.nodeTopology), - 'storageClassName': obj.storageClassName, + capacity: obj.capacity?.value, + maximumVolumeSize: obj.maximumVolumeSize?.value, + metadata: toJson_ObjectMeta(obj.metadata), + nodeTopology: toJson_LabelSelector(obj.nodeTopology), + storageClassName: obj.storageClassName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16517,21 +18251,27 @@ export interface KubeCsiStorageCapacityListV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.CSIStorageCapacityList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCsiStorageCapacityListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCsiStorageCapacityListV1Beta1Props(obj: KubeCsiStorageCapacityListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCsiStorageCapacityListV1Beta1Props( + obj: KubeCsiStorageCapacityListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCsiStorageCapacityV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCsiStorageCapacityV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16599,27 +18339,41 @@ export interface KubeStorageClassV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.StorageClass#volumeBindingMode */ readonly volumeBindingMode?: string; - } /** * Converts an object of type 'KubeStorageClassV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeStorageClassV1Beta1Props(obj: KubeStorageClassV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeStorageClassV1Beta1Props( + obj: KubeStorageClassV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'allowVolumeExpansion': obj.allowVolumeExpansion, - 'allowedTopologies': obj.allowedTopologies?.map(y => toJson_TopologySelectorTerm(y)), - 'metadata': toJson_ObjectMeta(obj.metadata), - 'mountOptions': obj.mountOptions?.map(y => y), - 'parameters': ((obj.parameters) === undefined) ? undefined : (Object.entries(obj.parameters).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'provisioner': obj.provisioner, - 'reclaimPolicy': obj.reclaimPolicy, - 'volumeBindingMode': obj.volumeBindingMode, + allowVolumeExpansion: obj.allowVolumeExpansion, + allowedTopologies: obj.allowedTopologies?.map((y) => + toJson_TopologySelectorTerm(y) + ), + metadata: toJson_ObjectMeta(obj.metadata), + mountOptions: obj.mountOptions?.map((y) => y), + parameters: + obj.parameters === undefined + ? undefined + : Object.entries(obj.parameters).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + provisioner: obj.provisioner, + reclaimPolicy: obj.reclaimPolicy, + volumeBindingMode: obj.volumeBindingMode, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16642,21 +18396,27 @@ export interface KubeStorageClassListV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.StorageClassList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeStorageClassListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeStorageClassListV1Beta1Props(obj: KubeStorageClassListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeStorageClassListV1Beta1Props( + obj: KubeStorageClassListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeStorageClassV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeStorageClassV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16681,21 +18441,27 @@ export interface KubeVolumeAttachmentV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.VolumeAttachment#spec */ readonly spec: VolumeAttachmentSpecV1Beta1; - } /** * Converts an object of type 'KubeVolumeAttachmentV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeVolumeAttachmentV1Beta1Props(obj: KubeVolumeAttachmentV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeVolumeAttachmentV1Beta1Props( + obj: KubeVolumeAttachmentV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_VolumeAttachmentSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_VolumeAttachmentSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16718,21 +18484,27 @@ export interface KubeVolumeAttachmentListV1Beta1Props { * @schema io.k8s.api.storage.v1beta1.VolumeAttachmentList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeVolumeAttachmentListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeVolumeAttachmentListV1Beta1Props(obj: KubeVolumeAttachmentListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeVolumeAttachmentListV1Beta1Props( + obj: KubeVolumeAttachmentListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeVolumeAttachmentV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeVolumeAttachmentV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16753,21 +18525,27 @@ export interface KubeCustomResourceDefinitionProps { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceDefinition#spec */ readonly spec: CustomResourceDefinitionSpec; - } /** * Converts an object of type 'KubeCustomResourceDefinitionProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCustomResourceDefinitionProps(obj: KubeCustomResourceDefinitionProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCustomResourceDefinitionProps( + obj: KubeCustomResourceDefinitionProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CustomResourceDefinitionSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CustomResourceDefinitionSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16788,21 +18566,27 @@ export interface KubeCustomResourceDefinitionListProps { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceDefinitionList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCustomResourceDefinitionListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCustomResourceDefinitionListProps(obj: KubeCustomResourceDefinitionListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCustomResourceDefinitionListProps( + obj: KubeCustomResourceDefinitionListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCustomResourceDefinitionProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeCustomResourceDefinitionProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16823,21 +18607,27 @@ export interface KubeCustomResourceDefinitionV1Beta1Props { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceDefinition#spec */ readonly spec: CustomResourceDefinitionSpecV1Beta1; - } /** * Converts an object of type 'KubeCustomResourceDefinitionV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCustomResourceDefinitionV1Beta1Props(obj: KubeCustomResourceDefinitionV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCustomResourceDefinitionV1Beta1Props( + obj: KubeCustomResourceDefinitionV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_CustomResourceDefinitionSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_CustomResourceDefinitionSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16858,21 +18648,29 @@ export interface KubeCustomResourceDefinitionListV1Beta1Props { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceDefinitionList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeCustomResourceDefinitionListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeCustomResourceDefinitionListV1Beta1Props(obj: KubeCustomResourceDefinitionListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeCustomResourceDefinitionListV1Beta1Props( + obj: KubeCustomResourceDefinitionListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeCustomResourceDefinitionV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => + toJson_KubeCustomResourceDefinitionV1Beta1Props(y) + ), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16916,24 +18714,30 @@ export interface KubeStatusProps { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.Status#reason */ readonly reason?: string; - } /** * Converts an object of type 'KubeStatusProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeStatusProps(obj: KubeStatusProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeStatusProps( + obj: KubeStatusProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'code': obj.code, - 'details': toJson_StatusDetails(obj.details), - 'message': obj.message, - 'metadata': toJson_ListMeta(obj.metadata), - 'reason': obj.reason, + code: obj.code, + details: toJson_StatusDetails(obj.details), + message: obj.message, + metadata: toJson_ListMeta(obj.metadata), + reason: obj.reason, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16954,21 +18758,27 @@ export interface KubeApiServiceProps { * @schema io.k8s.kube-aggregator.pkg.apis.apiregistration.v1.APIService#spec */ readonly spec?: ApiServiceSpec; - } /** * Converts an object of type 'KubeApiServiceProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeApiServiceProps(obj: KubeApiServiceProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeApiServiceProps( + obj: KubeApiServiceProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_ApiServiceSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_ApiServiceSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -16987,21 +18797,27 @@ export interface KubeApiServiceListProps { * @schema io.k8s.kube-aggregator.pkg.apis.apiregistration.v1.APIServiceList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeApiServiceListProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeApiServiceListProps(obj: KubeApiServiceListProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeApiServiceListProps( + obj: KubeApiServiceListProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeApiServiceProps(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeApiServiceProps(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -17022,21 +18838,27 @@ export interface KubeApiServiceV1Beta1Props { * @schema io.k8s.kube-aggregator.pkg.apis.apiregistration.v1beta1.APIService#spec */ readonly spec?: ApiServiceSpecV1Beta1; - } /** * Converts an object of type 'KubeApiServiceV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeApiServiceV1Beta1Props(obj: KubeApiServiceV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeApiServiceV1Beta1Props( + obj: KubeApiServiceV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_ApiServiceSpecV1Beta1(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_ApiServiceSpecV1Beta1(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -17055,21 +18877,27 @@ export interface KubeApiServiceListV1Beta1Props { * @schema io.k8s.kube-aggregator.pkg.apis.apiregistration.v1beta1.APIServiceList#metadata */ readonly metadata?: ListMeta; - } /** * Converts an object of type 'KubeApiServiceListV1Beta1Props' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KubeApiServiceListV1Beta1Props(obj: KubeApiServiceListV1Beta1Props | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KubeApiServiceListV1Beta1Props( + obj: KubeApiServiceListV1Beta1Props | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KubeApiServiceV1Beta1Props(y)), - 'metadata': toJson_ListMeta(obj.metadata), + items: obj.items?.map((y) => toJson_KubeApiServiceV1Beta1Props(y)), + metadata: toJson_ListMeta(obj.metadata), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -17206,35 +19034,53 @@ export interface ObjectMeta { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta#uid */ readonly uid?: string; - } /** * Converts an object of type 'ObjectMeta' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ObjectMeta(obj: ObjectMeta | undefined): Record | undefined { - if (obj === undefined) { return undefined; } - const result = { - 'annotations': ((obj.annotations) === undefined) ? undefined : (Object.entries(obj.annotations).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'clusterName': obj.clusterName, - 'creationTimestamp': obj.creationTimestamp?.toISOString(), - 'deletionGracePeriodSeconds': obj.deletionGracePeriodSeconds, - 'deletionTimestamp': obj.deletionTimestamp?.toISOString(), - 'finalizers': obj.finalizers?.map(y => y), - 'generateName': obj.generateName, - 'generation': obj.generation, - 'labels': ((obj.labels) === undefined) ? undefined : (Object.entries(obj.labels).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'managedFields': obj.managedFields?.map(y => toJson_ManagedFieldsEntry(y)), - 'name': obj.name, - 'namespace': obj.namespace, - 'ownerReferences': obj.ownerReferences?.map(y => toJson_OwnerReference(y)), - 'resourceVersion': obj.resourceVersion, - 'selfLink': obj.selfLink, - 'uid': obj.uid, - }; - // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); +export function toJson_ObjectMeta( + obj: ObjectMeta | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } + const result = { + annotations: + obj.annotations === undefined + ? undefined + : Object.entries(obj.annotations).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + clusterName: obj.clusterName, + creationTimestamp: obj.creationTimestamp?.toISOString(), + deletionGracePeriodSeconds: obj.deletionGracePeriodSeconds, + deletionTimestamp: obj.deletionTimestamp?.toISOString(), + finalizers: obj.finalizers?.map((y) => y), + generateName: obj.generateName, + generation: obj.generation, + labels: + obj.labels === undefined + ? undefined + : Object.entries(obj.labels).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + managedFields: obj.managedFields?.map((y) => toJson_ManagedFieldsEntry(y)), + name: obj.name, + namespace: obj.namespace, + ownerReferences: obj.ownerReferences?.map((y) => toJson_OwnerReference(y)), + resourceVersion: obj.resourceVersion, + selfLink: obj.selfLink, + uid: obj.uid, + }; + // filter undefined values + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -17368,30 +19214,36 @@ export interface MutatingWebhook { * @schema io.k8s.api.admissionregistration.v1.MutatingWebhook#timeoutSeconds */ readonly timeoutSeconds?: number; - } /** * Converts an object of type 'MutatingWebhook' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_MutatingWebhook(obj: MutatingWebhook | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_MutatingWebhook( + obj: MutatingWebhook | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'admissionReviewVersions': obj.admissionReviewVersions?.map(y => y), - 'clientConfig': toJson_WebhookClientConfig(obj.clientConfig), - 'failurePolicy': obj.failurePolicy, - 'matchPolicy': obj.matchPolicy, - 'name': obj.name, - 'namespaceSelector': toJson_LabelSelector(obj.namespaceSelector), - 'objectSelector': toJson_LabelSelector(obj.objectSelector), - 'reinvocationPolicy': obj.reinvocationPolicy, - 'rules': obj.rules?.map(y => toJson_RuleWithOperations(y)), - 'sideEffects': obj.sideEffects, - 'timeoutSeconds': obj.timeoutSeconds, + admissionReviewVersions: obj.admissionReviewVersions?.map((y) => y), + clientConfig: toJson_WebhookClientConfig(obj.clientConfig), + failurePolicy: obj.failurePolicy, + matchPolicy: obj.matchPolicy, + name: obj.name, + namespaceSelector: toJson_LabelSelector(obj.namespaceSelector), + objectSelector: toJson_LabelSelector(obj.objectSelector), + reinvocationPolicy: obj.reinvocationPolicy, + rules: obj.rules?.map((y) => toJson_RuleWithOperations(y)), + sideEffects: obj.sideEffects, + timeoutSeconds: obj.timeoutSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -17430,23 +19282,29 @@ export interface ListMeta { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.ListMeta#selfLink */ readonly selfLink?: string; - } /** * Converts an object of type 'ListMeta' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ListMeta(obj: ListMeta | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ListMeta( + obj: ListMeta | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'continue': obj.continue, - 'remainingItemCount': obj.remainingItemCount, - 'resourceVersion': obj.resourceVersion, - 'selfLink': obj.selfLink, + continue: obj.continue, + remainingItemCount: obj.remainingItemCount, + resourceVersion: obj.resourceVersion, + selfLink: obj.selfLink, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -17566,29 +19424,35 @@ export interface ValidatingWebhook { * @schema io.k8s.api.admissionregistration.v1.ValidatingWebhook#timeoutSeconds */ readonly timeoutSeconds?: number; - } /** * Converts an object of type 'ValidatingWebhook' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ValidatingWebhook(obj: ValidatingWebhook | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ValidatingWebhook( + obj: ValidatingWebhook | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'admissionReviewVersions': obj.admissionReviewVersions?.map(y => y), - 'clientConfig': toJson_WebhookClientConfig(obj.clientConfig), - 'failurePolicy': obj.failurePolicy, - 'matchPolicy': obj.matchPolicy, - 'name': obj.name, - 'namespaceSelector': toJson_LabelSelector(obj.namespaceSelector), - 'objectSelector': toJson_LabelSelector(obj.objectSelector), - 'rules': obj.rules?.map(y => toJson_RuleWithOperations(y)), - 'sideEffects': obj.sideEffects, - 'timeoutSeconds': obj.timeoutSeconds, + admissionReviewVersions: obj.admissionReviewVersions?.map((y) => y), + clientConfig: toJson_WebhookClientConfig(obj.clientConfig), + failurePolicy: obj.failurePolicy, + matchPolicy: obj.matchPolicy, + name: obj.name, + namespaceSelector: toJson_LabelSelector(obj.namespaceSelector), + objectSelector: toJson_LabelSelector(obj.objectSelector), + rules: obj.rules?.map((y) => toJson_RuleWithOperations(y)), + sideEffects: obj.sideEffects, + timeoutSeconds: obj.timeoutSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -17724,30 +19588,36 @@ export interface MutatingWebhookV1Beta1 { * @schema io.k8s.api.admissionregistration.v1beta1.MutatingWebhook#timeoutSeconds */ readonly timeoutSeconds?: number; - } /** * Converts an object of type 'MutatingWebhookV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_MutatingWebhookV1Beta1(obj: MutatingWebhookV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_MutatingWebhookV1Beta1( + obj: MutatingWebhookV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'admissionReviewVersions': obj.admissionReviewVersions?.map(y => y), - 'clientConfig': toJson_WebhookClientConfigV1Beta1(obj.clientConfig), - 'failurePolicy': obj.failurePolicy, - 'matchPolicy': obj.matchPolicy, - 'name': obj.name, - 'namespaceSelector': toJson_LabelSelector(obj.namespaceSelector), - 'objectSelector': toJson_LabelSelector(obj.objectSelector), - 'reinvocationPolicy': obj.reinvocationPolicy, - 'rules': obj.rules?.map(y => toJson_RuleWithOperationsV1Beta1(y)), - 'sideEffects': obj.sideEffects, - 'timeoutSeconds': obj.timeoutSeconds, + admissionReviewVersions: obj.admissionReviewVersions?.map((y) => y), + clientConfig: toJson_WebhookClientConfigV1Beta1(obj.clientConfig), + failurePolicy: obj.failurePolicy, + matchPolicy: obj.matchPolicy, + name: obj.name, + namespaceSelector: toJson_LabelSelector(obj.namespaceSelector), + objectSelector: toJson_LabelSelector(obj.objectSelector), + reinvocationPolicy: obj.reinvocationPolicy, + rules: obj.rules?.map((y) => toJson_RuleWithOperationsV1Beta1(y)), + sideEffects: obj.sideEffects, + timeoutSeconds: obj.timeoutSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -17869,29 +19739,35 @@ export interface ValidatingWebhookV1Beta1 { * @schema io.k8s.api.admissionregistration.v1beta1.ValidatingWebhook#timeoutSeconds */ readonly timeoutSeconds?: number; - } /** * Converts an object of type 'ValidatingWebhookV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ValidatingWebhookV1Beta1(obj: ValidatingWebhookV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ValidatingWebhookV1Beta1( + obj: ValidatingWebhookV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'admissionReviewVersions': obj.admissionReviewVersions?.map(y => y), - 'clientConfig': toJson_WebhookClientConfigV1Beta1(obj.clientConfig), - 'failurePolicy': obj.failurePolicy, - 'matchPolicy': obj.matchPolicy, - 'name': obj.name, - 'namespaceSelector': toJson_LabelSelector(obj.namespaceSelector), - 'objectSelector': toJson_LabelSelector(obj.objectSelector), - 'rules': obj.rules?.map(y => toJson_RuleWithOperationsV1Beta1(y)), - 'sideEffects': obj.sideEffects, - 'timeoutSeconds': obj.timeoutSeconds, + admissionReviewVersions: obj.admissionReviewVersions?.map((y) => y), + clientConfig: toJson_WebhookClientConfigV1Beta1(obj.clientConfig), + failurePolicy: obj.failurePolicy, + matchPolicy: obj.matchPolicy, + name: obj.name, + namespaceSelector: toJson_LabelSelector(obj.namespaceSelector), + objectSelector: toJson_LabelSelector(obj.objectSelector), + rules: obj.rules?.map((y) => toJson_RuleWithOperationsV1Beta1(y)), + sideEffects: obj.sideEffects, + timeoutSeconds: obj.timeoutSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -17937,24 +19813,30 @@ export interface DaemonSetSpec { * @schema io.k8s.api.apps.v1.DaemonSetSpec#updateStrategy */ readonly updateStrategy?: DaemonSetUpdateStrategy; - } /** * Converts an object of type 'DaemonSetSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_DaemonSetSpec(obj: DaemonSetSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_DaemonSetSpec( + obj: DaemonSetSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'minReadySeconds': obj.minReadySeconds, - 'revisionHistoryLimit': obj.revisionHistoryLimit, - 'selector': toJson_LabelSelector(obj.selector), - 'template': toJson_PodTemplateSpec(obj.template), - 'updateStrategy': toJson_DaemonSetUpdateStrategy(obj.updateStrategy), + minReadySeconds: obj.minReadySeconds, + revisionHistoryLimit: obj.revisionHistoryLimit, + selector: toJson_LabelSelector(obj.selector), + template: toJson_PodTemplateSpec(obj.template), + updateStrategy: toJson_DaemonSetUpdateStrategy(obj.updateStrategy), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18023,27 +19905,33 @@ export interface DeploymentSpec { * @schema io.k8s.api.apps.v1.DeploymentSpec#template */ readonly template: PodTemplateSpec; - } /** * Converts an object of type 'DeploymentSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_DeploymentSpec(obj: DeploymentSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_DeploymentSpec( + obj: DeploymentSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'minReadySeconds': obj.minReadySeconds, - 'paused': obj.paused, - 'progressDeadlineSeconds': obj.progressDeadlineSeconds, - 'replicas': obj.replicas, - 'revisionHistoryLimit': obj.revisionHistoryLimit, - 'selector': toJson_LabelSelector(obj.selector), - 'strategy': toJson_DeploymentStrategy(obj.strategy), - 'template': toJson_PodTemplateSpec(obj.template), + minReadySeconds: obj.minReadySeconds, + paused: obj.paused, + progressDeadlineSeconds: obj.progressDeadlineSeconds, + replicas: obj.replicas, + revisionHistoryLimit: obj.revisionHistoryLimit, + selector: toJson_LabelSelector(obj.selector), + strategy: toJson_DeploymentStrategy(obj.strategy), + template: toJson_PodTemplateSpec(obj.template), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18082,23 +19970,29 @@ export interface ReplicaSetSpec { * @schema io.k8s.api.apps.v1.ReplicaSetSpec#template */ readonly template?: PodTemplateSpec; - } /** * Converts an object of type 'ReplicaSetSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ReplicaSetSpec(obj: ReplicaSetSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ReplicaSetSpec( + obj: ReplicaSetSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'minReadySeconds': obj.minReadySeconds, - 'replicas': obj.replicas, - 'selector': toJson_LabelSelector(obj.selector), - 'template': toJson_PodTemplateSpec(obj.template), + minReadySeconds: obj.minReadySeconds, + replicas: obj.replicas, + selector: toJson_LabelSelector(obj.selector), + template: toJson_PodTemplateSpec(obj.template), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18163,27 +20057,35 @@ export interface StatefulSetSpec { * @schema io.k8s.api.apps.v1.StatefulSetSpec#volumeClaimTemplates */ readonly volumeClaimTemplates?: KubePersistentVolumeClaimProps[]; - } /** * Converts an object of type 'StatefulSetSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_StatefulSetSpec(obj: StatefulSetSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_StatefulSetSpec( + obj: StatefulSetSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'podManagementPolicy': obj.podManagementPolicy, - 'replicas': obj.replicas, - 'revisionHistoryLimit': obj.revisionHistoryLimit, - 'selector': toJson_LabelSelector(obj.selector), - 'serviceName': obj.serviceName, - 'template': toJson_PodTemplateSpec(obj.template), - 'updateStrategy': toJson_StatefulSetUpdateStrategy(obj.updateStrategy), - 'volumeClaimTemplates': obj.volumeClaimTemplates?.map(y => toJson_KubePersistentVolumeClaimProps(y)), + podManagementPolicy: obj.podManagementPolicy, + replicas: obj.replicas, + revisionHistoryLimit: obj.revisionHistoryLimit, + selector: toJson_LabelSelector(obj.selector), + serviceName: obj.serviceName, + template: toJson_PodTemplateSpec(obj.template), + updateStrategy: toJson_StatefulSetUpdateStrategy(obj.updateStrategy), + volumeClaimTemplates: obj.volumeClaimTemplates?.map((y) => + toJson_KubePersistentVolumeClaimProps(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18213,22 +20115,28 @@ export interface TokenRequestSpec { * @schema io.k8s.api.authentication.v1.TokenRequestSpec#expirationSeconds */ readonly expirationSeconds?: number; - } /** * Converts an object of type 'TokenRequestSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TokenRequestSpec(obj: TokenRequestSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TokenRequestSpec( + obj: TokenRequestSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'audiences': obj.audiences?.map(y => y), - 'boundObjectRef': toJson_BoundObjectReference(obj.boundObjectRef), - 'expirationSeconds': obj.expirationSeconds, + audiences: obj.audiences?.map((y) => y), + boundObjectRef: toJson_BoundObjectReference(obj.boundObjectRef), + expirationSeconds: obj.expirationSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18251,21 +20159,27 @@ export interface TokenReviewSpec { * @schema io.k8s.api.authentication.v1.TokenReviewSpec#token */ readonly token?: string; - } /** * Converts an object of type 'TokenReviewSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TokenReviewSpec(obj: TokenReviewSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TokenReviewSpec( + obj: TokenReviewSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'audiences': obj.audiences?.map(y => y), - 'token': obj.token, + audiences: obj.audiences?.map((y) => y), + token: obj.token, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18288,21 +20202,27 @@ export interface TokenReviewSpecV1Beta1 { * @schema io.k8s.api.authentication.v1beta1.TokenReviewSpec#token */ readonly token?: string; - } /** * Converts an object of type 'TokenReviewSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TokenReviewSpecV1Beta1(obj: TokenReviewSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TokenReviewSpecV1Beta1( + obj: TokenReviewSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'audiences': obj.audiences?.map(y => y), - 'token': obj.token, + audiences: obj.audiences?.map((y) => y), + token: obj.token, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18353,25 +20273,40 @@ export interface SubjectAccessReviewSpec { * @schema io.k8s.api.authorization.v1.SubjectAccessReviewSpec#user */ readonly user?: string; - } /** * Converts an object of type 'SubjectAccessReviewSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SubjectAccessReviewSpec(obj: SubjectAccessReviewSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SubjectAccessReviewSpec( + obj: SubjectAccessReviewSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'extra': ((obj.extra) === undefined) ? undefined : (Object.entries(obj.extra).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.map(y => y) }), {})), - 'groups': obj.groups?.map(y => y), - 'nonResourceAttributes': toJson_NonResourceAttributes(obj.nonResourceAttributes), - 'resourceAttributes': toJson_ResourceAttributes(obj.resourceAttributes), - 'uid': obj.uid, - 'user': obj.user, + extra: + obj.extra === undefined + ? undefined + : Object.entries(obj.extra).reduce( + (r, i) => + i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.map((y) => y) }, + {} + ), + groups: obj.groups?.map((y) => y), + nonResourceAttributes: toJson_NonResourceAttributes( + obj.nonResourceAttributes + ), + resourceAttributes: toJson_ResourceAttributes(obj.resourceAttributes), + uid: obj.uid, + user: obj.user, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18394,21 +20329,29 @@ export interface SelfSubjectAccessReviewSpec { * @schema io.k8s.api.authorization.v1.SelfSubjectAccessReviewSpec#resourceAttributes */ readonly resourceAttributes?: ResourceAttributes; - } /** * Converts an object of type 'SelfSubjectAccessReviewSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SelfSubjectAccessReviewSpec(obj: SelfSubjectAccessReviewSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SelfSubjectAccessReviewSpec( + obj: SelfSubjectAccessReviewSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nonResourceAttributes': toJson_NonResourceAttributes(obj.nonResourceAttributes), - 'resourceAttributes': toJson_ResourceAttributes(obj.resourceAttributes), + nonResourceAttributes: toJson_NonResourceAttributes( + obj.nonResourceAttributes + ), + resourceAttributes: toJson_ResourceAttributes(obj.resourceAttributes), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18422,20 +20365,26 @@ export interface SelfSubjectRulesReviewSpec { * @schema io.k8s.api.authorization.v1.SelfSubjectRulesReviewSpec#namespace */ readonly namespace?: string; - } /** * Converts an object of type 'SelfSubjectRulesReviewSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SelfSubjectRulesReviewSpec(obj: SelfSubjectRulesReviewSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SelfSubjectRulesReviewSpec( + obj: SelfSubjectRulesReviewSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'namespace': obj.namespace, + namespace: obj.namespace, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18486,25 +20435,42 @@ export interface SubjectAccessReviewSpecV1Beta1 { * @schema io.k8s.api.authorization.v1beta1.SubjectAccessReviewSpec#user */ readonly user?: string; - } /** * Converts an object of type 'SubjectAccessReviewSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SubjectAccessReviewSpecV1Beta1(obj: SubjectAccessReviewSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SubjectAccessReviewSpecV1Beta1( + obj: SubjectAccessReviewSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'extra': ((obj.extra) === undefined) ? undefined : (Object.entries(obj.extra).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.map(y => y) }), {})), - 'group': obj.group?.map(y => y), - 'nonResourceAttributes': toJson_NonResourceAttributesV1Beta1(obj.nonResourceAttributes), - 'resourceAttributes': toJson_ResourceAttributesV1Beta1(obj.resourceAttributes), - 'uid': obj.uid, - 'user': obj.user, + extra: + obj.extra === undefined + ? undefined + : Object.entries(obj.extra).reduce( + (r, i) => + i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.map((y) => y) }, + {} + ), + group: obj.group?.map((y) => y), + nonResourceAttributes: toJson_NonResourceAttributesV1Beta1( + obj.nonResourceAttributes + ), + resourceAttributes: toJson_ResourceAttributesV1Beta1( + obj.resourceAttributes + ), + uid: obj.uid, + user: obj.user, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18527,21 +20493,31 @@ export interface SelfSubjectAccessReviewSpecV1Beta1 { * @schema io.k8s.api.authorization.v1beta1.SelfSubjectAccessReviewSpec#resourceAttributes */ readonly resourceAttributes?: ResourceAttributesV1Beta1; - } /** * Converts an object of type 'SelfSubjectAccessReviewSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SelfSubjectAccessReviewSpecV1Beta1(obj: SelfSubjectAccessReviewSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SelfSubjectAccessReviewSpecV1Beta1( + obj: SelfSubjectAccessReviewSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nonResourceAttributes': toJson_NonResourceAttributesV1Beta1(obj.nonResourceAttributes), - 'resourceAttributes': toJson_ResourceAttributesV1Beta1(obj.resourceAttributes), + nonResourceAttributes: toJson_NonResourceAttributesV1Beta1( + obj.nonResourceAttributes + ), + resourceAttributes: toJson_ResourceAttributesV1Beta1( + obj.resourceAttributes + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18555,20 +20531,26 @@ export interface SelfSubjectRulesReviewSpecV1Beta1 { * @schema io.k8s.api.authorization.v1beta1.SelfSubjectRulesReviewSpec#namespace */ readonly namespace?: string; - } /** * Converts an object of type 'SelfSubjectRulesReviewSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SelfSubjectRulesReviewSpecV1Beta1(obj: SelfSubjectRulesReviewSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SelfSubjectRulesReviewSpecV1Beta1( + obj: SelfSubjectRulesReviewSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'namespace': obj.namespace, + namespace: obj.namespace, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18605,23 +20587,29 @@ export interface HorizontalPodAutoscalerSpec { * @schema io.k8s.api.autoscaling.v1.HorizontalPodAutoscalerSpec#targetCPUUtilizationPercentage */ readonly targetCpuUtilizationPercentage?: number; - } /** * Converts an object of type 'HorizontalPodAutoscalerSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HorizontalPodAutoscalerSpec(obj: HorizontalPodAutoscalerSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HorizontalPodAutoscalerSpec( + obj: HorizontalPodAutoscalerSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'maxReplicas': obj.maxReplicas, - 'minReplicas': obj.minReplicas, - 'scaleTargetRef': toJson_CrossVersionObjectReference(obj.scaleTargetRef), - 'targetCPUUtilizationPercentage': obj.targetCpuUtilizationPercentage, + maxReplicas: obj.maxReplicas, + minReplicas: obj.minReplicas, + scaleTargetRef: toJson_CrossVersionObjectReference(obj.scaleTargetRef), + targetCPUUtilizationPercentage: obj.targetCpuUtilizationPercentage, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18637,20 +20625,26 @@ export interface ScaleSpec { * @schema io.k8s.api.autoscaling.v1.ScaleSpec#replicas */ readonly replicas?: number; - } /** * Converts an object of type 'ScaleSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ScaleSpec(obj: ScaleSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ScaleSpec( + obj: ScaleSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'replicas': obj.replicas, + replicas: obj.replicas, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18687,23 +20681,31 @@ export interface HorizontalPodAutoscalerSpecV2Beta1 { * @schema io.k8s.api.autoscaling.v2beta1.HorizontalPodAutoscalerSpec#scaleTargetRef */ readonly scaleTargetRef: CrossVersionObjectReferenceV2Beta1; - } /** * Converts an object of type 'HorizontalPodAutoscalerSpecV2Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HorizontalPodAutoscalerSpecV2Beta1(obj: HorizontalPodAutoscalerSpecV2Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HorizontalPodAutoscalerSpecV2Beta1( + obj: HorizontalPodAutoscalerSpecV2Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'maxReplicas': obj.maxReplicas, - 'metrics': obj.metrics?.map(y => toJson_MetricSpecV2Beta1(y)), - 'minReplicas': obj.minReplicas, - 'scaleTargetRef': toJson_CrossVersionObjectReferenceV2Beta1(obj.scaleTargetRef), + maxReplicas: obj.maxReplicas, + metrics: obj.metrics?.map((y) => toJson_MetricSpecV2Beta1(y)), + minReplicas: obj.minReplicas, + scaleTargetRef: toJson_CrossVersionObjectReferenceV2Beta1( + obj.scaleTargetRef + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18747,24 +20749,32 @@ export interface HorizontalPodAutoscalerSpecV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.HorizontalPodAutoscalerSpec#scaleTargetRef */ readonly scaleTargetRef: CrossVersionObjectReferenceV2Beta2; - } /** * Converts an object of type 'HorizontalPodAutoscalerSpecV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HorizontalPodAutoscalerSpecV2Beta2(obj: HorizontalPodAutoscalerSpecV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HorizontalPodAutoscalerSpecV2Beta2( + obj: HorizontalPodAutoscalerSpecV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'behavior': toJson_HorizontalPodAutoscalerBehaviorV2Beta2(obj.behavior), - 'maxReplicas': obj.maxReplicas, - 'metrics': obj.metrics?.map(y => toJson_MetricSpecV2Beta2(y)), - 'minReplicas': obj.minReplicas, - 'scaleTargetRef': toJson_CrossVersionObjectReferenceV2Beta2(obj.scaleTargetRef), + behavior: toJson_HorizontalPodAutoscalerBehaviorV2Beta2(obj.behavior), + maxReplicas: obj.maxReplicas, + metrics: obj.metrics?.map((y) => toJson_MetricSpecV2Beta2(y)), + minReplicas: obj.minReplicas, + scaleTargetRef: toJson_CrossVersionObjectReferenceV2Beta2( + obj.scaleTargetRef + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18825,26 +20835,32 @@ export interface CronJobSpec { * @schema io.k8s.api.batch.v1.CronJobSpec#suspend */ readonly suspend?: boolean; - } /** * Converts an object of type 'CronJobSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CronJobSpec(obj: CronJobSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CronJobSpec( + obj: CronJobSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'concurrencyPolicy': obj.concurrencyPolicy, - 'failedJobsHistoryLimit': obj.failedJobsHistoryLimit, - 'jobTemplate': toJson_JobTemplateSpec(obj.jobTemplate), - 'schedule': obj.schedule, - 'startingDeadlineSeconds': obj.startingDeadlineSeconds, - 'successfulJobsHistoryLimit': obj.successfulJobsHistoryLimit, - 'suspend': obj.suspend, + concurrencyPolicy: obj.concurrencyPolicy, + failedJobsHistoryLimit: obj.failedJobsHistoryLimit, + jobTemplate: toJson_JobTemplateSpec(obj.jobTemplate), + schedule: obj.schedule, + startingDeadlineSeconds: obj.startingDeadlineSeconds, + successfulJobsHistoryLimit: obj.successfulJobsHistoryLimit, + suspend: obj.suspend, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -18931,29 +20947,35 @@ export interface JobSpec { * @schema io.k8s.api.batch.v1.JobSpec#ttlSecondsAfterFinished */ readonly ttlSecondsAfterFinished?: number; - } /** * Converts an object of type 'JobSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_JobSpec(obj: JobSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_JobSpec( + obj: JobSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'activeDeadlineSeconds': obj.activeDeadlineSeconds, - 'backoffLimit': obj.backoffLimit, - 'completionMode': obj.completionMode, - 'completions': obj.completions, - 'manualSelector': obj.manualSelector, - 'parallelism': obj.parallelism, - 'selector': toJson_LabelSelector(obj.selector), - 'suspend': obj.suspend, - 'template': toJson_PodTemplateSpec(obj.template), - 'ttlSecondsAfterFinished': obj.ttlSecondsAfterFinished, + activeDeadlineSeconds: obj.activeDeadlineSeconds, + backoffLimit: obj.backoffLimit, + completionMode: obj.completionMode, + completions: obj.completions, + manualSelector: obj.manualSelector, + parallelism: obj.parallelism, + selector: toJson_LabelSelector(obj.selector), + suspend: obj.suspend, + template: toJson_PodTemplateSpec(obj.template), + ttlSecondsAfterFinished: obj.ttlSecondsAfterFinished, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19014,26 +21036,32 @@ export interface CronJobSpecV1Beta1 { * @schema io.k8s.api.batch.v1beta1.CronJobSpec#suspend */ readonly suspend?: boolean; - } /** * Converts an object of type 'CronJobSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CronJobSpecV1Beta1(obj: CronJobSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CronJobSpecV1Beta1( + obj: CronJobSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'concurrencyPolicy': obj.concurrencyPolicy, - 'failedJobsHistoryLimit': obj.failedJobsHistoryLimit, - 'jobTemplate': toJson_JobTemplateSpecV1Beta1(obj.jobTemplate), - 'schedule': obj.schedule, - 'startingDeadlineSeconds': obj.startingDeadlineSeconds, - 'successfulJobsHistoryLimit': obj.successfulJobsHistoryLimit, - 'suspend': obj.suspend, + concurrencyPolicy: obj.concurrencyPolicy, + failedJobsHistoryLimit: obj.failedJobsHistoryLimit, + jobTemplate: toJson_JobTemplateSpecV1Beta1(obj.jobTemplate), + schedule: obj.schedule, + startingDeadlineSeconds: obj.startingDeadlineSeconds, + successfulJobsHistoryLimit: obj.successfulJobsHistoryLimit, + suspend: obj.suspend, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19124,26 +21152,39 @@ export interface CertificateSigningRequestSpec { * @schema io.k8s.api.certificates.v1.CertificateSigningRequestSpec#username */ readonly username?: string; - } /** * Converts an object of type 'CertificateSigningRequestSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CertificateSigningRequestSpec(obj: CertificateSigningRequestSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CertificateSigningRequestSpec( + obj: CertificateSigningRequestSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'extra': ((obj.extra) === undefined) ? undefined : (Object.entries(obj.extra).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.map(y => y) }), {})), - 'groups': obj.groups?.map(y => y), - 'request': obj.request, - 'signerName': obj.signerName, - 'uid': obj.uid, - 'usages': obj.usages?.map(y => y), - 'username': obj.username, + extra: + obj.extra === undefined + ? undefined + : Object.entries(obj.extra).reduce( + (r, i) => + i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.map((y) => y) }, + {} + ), + groups: obj.groups?.map((y) => y), + request: obj.request, + signerName: obj.signerName, + uid: obj.uid, + usages: obj.usages?.map((y) => y), + username: obj.username, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19232,26 +21273,39 @@ export interface CertificateSigningRequestSpecV1Beta1 { * @schema io.k8s.api.certificates.v1beta1.CertificateSigningRequestSpec#username */ readonly username?: string; - } /** * Converts an object of type 'CertificateSigningRequestSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CertificateSigningRequestSpecV1Beta1(obj: CertificateSigningRequestSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CertificateSigningRequestSpecV1Beta1( + obj: CertificateSigningRequestSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'extra': ((obj.extra) === undefined) ? undefined : (Object.entries(obj.extra).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.map(y => y) }), {})), - 'groups': obj.groups?.map(y => y), - 'request': obj.request, - 'signerName': obj.signerName, - 'uid': obj.uid, - 'usages': obj.usages?.map(y => y), - 'username': obj.username, + extra: + obj.extra === undefined + ? undefined + : Object.entries(obj.extra).reduce( + (r, i) => + i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.map((y) => y) }, + {} + ), + groups: obj.groups?.map((y) => y), + request: obj.request, + signerName: obj.signerName, + uid: obj.uid, + usages: obj.usages?.map((y) => y), + username: obj.username, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19295,24 +21349,30 @@ export interface LeaseSpec { * @schema io.k8s.api.coordination.v1.LeaseSpec#renewTime */ readonly renewTime?: Date; - } /** * Converts an object of type 'LeaseSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LeaseSpec(obj: LeaseSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_LeaseSpec( + obj: LeaseSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'acquireTime': obj.acquireTime?.toISOString(), - 'holderIdentity': obj.holderIdentity, - 'leaseDurationSeconds': obj.leaseDurationSeconds, - 'leaseTransitions': obj.leaseTransitions, - 'renewTime': obj.renewTime?.toISOString(), + acquireTime: obj.acquireTime?.toISOString(), + holderIdentity: obj.holderIdentity, + leaseDurationSeconds: obj.leaseDurationSeconds, + leaseTransitions: obj.leaseTransitions, + renewTime: obj.renewTime?.toISOString(), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19356,24 +21416,30 @@ export interface LeaseSpecV1Beta1 { * @schema io.k8s.api.coordination.v1beta1.LeaseSpec#renewTime */ readonly renewTime?: Date; - } /** * Converts an object of type 'LeaseSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LeaseSpecV1Beta1(obj: LeaseSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_LeaseSpecV1Beta1( + obj: LeaseSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'acquireTime': obj.acquireTime?.toISOString(), - 'holderIdentity': obj.holderIdentity, - 'leaseDurationSeconds': obj.leaseDurationSeconds, - 'leaseTransitions': obj.leaseTransitions, - 'renewTime': obj.renewTime?.toISOString(), + acquireTime: obj.acquireTime?.toISOString(), + holderIdentity: obj.holderIdentity, + leaseDurationSeconds: obj.leaseDurationSeconds, + leaseTransitions: obj.leaseTransitions, + renewTime: obj.renewTime?.toISOString(), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19431,26 +21497,32 @@ export interface ObjectReference { * @schema io.k8s.api.core.v1.ObjectReference#uid */ readonly uid?: string; - } /** * Converts an object of type 'ObjectReference' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ObjectReference(obj: ObjectReference | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ObjectReference( + obj: ObjectReference | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'fieldPath': obj.fieldPath, - 'kind': obj.kind, - 'name': obj.name, - 'namespace': obj.namespace, - 'resourceVersion': obj.resourceVersion, - 'uid': obj.uid, + apiVersion: obj.apiVersion, + fieldPath: obj.fieldPath, + kind: obj.kind, + name: obj.name, + namespace: obj.namespace, + resourceVersion: obj.resourceVersion, + uid: obj.uid, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19487,23 +21559,29 @@ export interface ComponentCondition { * @schema io.k8s.api.core.v1.ComponentCondition#type */ readonly type: string; - } /** * Converts an object of type 'ComponentCondition' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ComponentCondition(obj: ComponentCondition | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ComponentCondition( + obj: ComponentCondition | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'error': obj.error, - 'message': obj.message, - 'status': obj.status, - 'type': obj.type, + error: obj.error, + message: obj.message, + status: obj.status, + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19540,22 +21618,30 @@ export interface EndpointSubset { * @schema io.k8s.api.core.v1.EndpointSubset#ports */ readonly ports?: EndpointPort[]; - } /** * Converts an object of type 'EndpointSubset' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EndpointSubset(obj: EndpointSubset | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EndpointSubset( + obj: EndpointSubset | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'addresses': obj.addresses?.map(y => toJson_EndpointAddress(y)), - 'notReadyAddresses': obj.notReadyAddresses?.map(y => toJson_EndpointAddress(y)), - 'ports': obj.ports?.map(y => toJson_EndpointPort(y)), + addresses: obj.addresses?.map((y) => toJson_EndpointAddress(y)), + notReadyAddresses: obj.notReadyAddresses?.map((y) => + toJson_EndpointAddress(y) + ), + ports: obj.ports?.map((y) => toJson_EndpointPort(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19731,42 +21817,48 @@ export interface EphemeralContainer { * @schema io.k8s.api.core.v1.EphemeralContainer#workingDir */ readonly workingDir?: string; - } /** * Converts an object of type 'EphemeralContainer' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EphemeralContainer(obj: EphemeralContainer | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EphemeralContainer( + obj: EphemeralContainer | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'args': obj.args?.map(y => y), - 'command': obj.command?.map(y => y), - 'env': obj.env?.map(y => toJson_EnvVar(y)), - 'envFrom': obj.envFrom?.map(y => toJson_EnvFromSource(y)), - 'image': obj.image, - 'imagePullPolicy': obj.imagePullPolicy, - 'lifecycle': toJson_Lifecycle(obj.lifecycle), - 'livenessProbe': toJson_Probe(obj.livenessProbe), - 'name': obj.name, - 'ports': obj.ports?.map(y => toJson_ContainerPort(y)), - 'readinessProbe': toJson_Probe(obj.readinessProbe), - 'resources': toJson_ResourceRequirements(obj.resources), - 'securityContext': toJson_SecurityContext(obj.securityContext), - 'startupProbe': toJson_Probe(obj.startupProbe), - 'stdin': obj.stdin, - 'stdinOnce': obj.stdinOnce, - 'targetContainerName': obj.targetContainerName, - 'terminationMessagePath': obj.terminationMessagePath, - 'terminationMessagePolicy': obj.terminationMessagePolicy, - 'tty': obj.tty, - 'volumeDevices': obj.volumeDevices?.map(y => toJson_VolumeDevice(y)), - 'volumeMounts': obj.volumeMounts?.map(y => toJson_VolumeMount(y)), - 'workingDir': obj.workingDir, + args: obj.args?.map((y) => y), + command: obj.command?.map((y) => y), + env: obj.env?.map((y) => toJson_EnvVar(y)), + envFrom: obj.envFrom?.map((y) => toJson_EnvFromSource(y)), + image: obj.image, + imagePullPolicy: obj.imagePullPolicy, + lifecycle: toJson_Lifecycle(obj.lifecycle), + livenessProbe: toJson_Probe(obj.livenessProbe), + name: obj.name, + ports: obj.ports?.map((y) => toJson_ContainerPort(y)), + readinessProbe: toJson_Probe(obj.readinessProbe), + resources: toJson_ResourceRequirements(obj.resources), + securityContext: toJson_SecurityContext(obj.securityContext), + startupProbe: toJson_Probe(obj.startupProbe), + stdin: obj.stdin, + stdinOnce: obj.stdinOnce, + targetContainerName: obj.targetContainerName, + terminationMessagePath: obj.terminationMessagePath, + terminationMessagePolicy: obj.terminationMessagePolicy, + tty: obj.tty, + volumeDevices: obj.volumeDevices?.map((y) => toJson_VolumeDevice(y)), + volumeMounts: obj.volumeMounts?.map((y) => toJson_VolumeMount(y)), + workingDir: obj.workingDir, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19789,21 +21881,27 @@ export interface EventSource { * @schema io.k8s.api.core.v1.EventSource#host */ readonly host?: string; - } /** * Converts an object of type 'EventSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EventSource(obj: EventSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EventSource( + obj: EventSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'component': obj.component, - 'host': obj.host, + component: obj.component, + host: obj.host, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19826,21 +21924,27 @@ export interface EventSeries { * @schema io.k8s.api.events.v1.EventSeries#lastObservedTime */ readonly lastObservedTime: Date; - } /** * Converts an object of type 'EventSeries' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EventSeries(obj: EventSeries | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EventSeries( + obj: EventSeries | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'count': obj.count, - 'lastObservedTime': obj.lastObservedTime?.toISOString(), + count: obj.count, + lastObservedTime: obj.lastObservedTime?.toISOString(), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19856,20 +21960,26 @@ export interface LimitRangeSpec { * @schema io.k8s.api.core.v1.LimitRangeSpec#limits */ readonly limits: LimitRangeItem[]; - } /** * Converts an object of type 'LimitRangeSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LimitRangeSpec(obj: LimitRangeSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_LimitRangeSpec( + obj: LimitRangeSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'limits': obj.limits?.map(y => toJson_LimitRangeItem(y)), + limits: obj.limits?.map((y) => toJson_LimitRangeItem(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19885,20 +21995,26 @@ export interface NamespaceSpec { * @schema io.k8s.api.core.v1.NamespaceSpec#finalizers */ readonly finalizers?: string[]; - } /** * Converts an object of type 'NamespaceSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NamespaceSpec(obj: NamespaceSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NamespaceSpec( + obj: NamespaceSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'finalizers': obj.finalizers?.map(y => y), + finalizers: obj.finalizers?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -19956,26 +22072,32 @@ export interface NodeSpec { * @schema io.k8s.api.core.v1.NodeSpec#unschedulable */ readonly unschedulable?: boolean; - } /** * Converts an object of type 'NodeSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NodeSpec(obj: NodeSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NodeSpec( + obj: NodeSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'configSource': toJson_NodeConfigSource(obj.configSource), - 'externalID': obj.externalId, - 'podCIDR': obj.podCidr, - 'podCIDRs': obj.podCidRs?.map(y => y), - 'providerID': obj.providerId, - 'taints': obj.taints?.map(y => toJson_Taint(y)), - 'unschedulable': obj.unschedulable, + configSource: toJson_NodeConfigSource(obj.configSource), + externalID: obj.externalId, + podCIDR: obj.podCidr, + podCIDRs: obj.podCidRs?.map((y) => y), + providerID: obj.providerId, + taints: obj.taints?.map((y) => toJson_Taint(y)), + unschedulable: obj.unschedulable, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -20194,49 +22316,67 @@ export interface PersistentVolumeSpec { * @schema io.k8s.api.core.v1.PersistentVolumeSpec#vsphereVolume */ readonly vsphereVolume?: VsphereVirtualDiskVolumeSource; - } /** * Converts an object of type 'PersistentVolumeSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PersistentVolumeSpec(obj: PersistentVolumeSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } - const result = { - 'accessModes': obj.accessModes?.map(y => y), - 'awsElasticBlockStore': toJson_AwsElasticBlockStoreVolumeSource(obj.awsElasticBlockStore), - 'azureDisk': toJson_AzureDiskVolumeSource(obj.azureDisk), - 'azureFile': toJson_AzureFilePersistentVolumeSource(obj.azureFile), - 'capacity': ((obj.capacity) === undefined) ? undefined : (Object.entries(obj.capacity).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), - 'cephfs': toJson_CephFsPersistentVolumeSource(obj.cephfs), - 'cinder': toJson_CinderPersistentVolumeSource(obj.cinder), - 'claimRef': toJson_ObjectReference(obj.claimRef), - 'csi': toJson_CsiPersistentVolumeSource(obj.csi), - 'fc': toJson_FcVolumeSource(obj.fc), - 'flexVolume': toJson_FlexPersistentVolumeSource(obj.flexVolume), - 'flocker': toJson_FlockerVolumeSource(obj.flocker), - 'gcePersistentDisk': toJson_GcePersistentDiskVolumeSource(obj.gcePersistentDisk), - 'glusterfs': toJson_GlusterfsPersistentVolumeSource(obj.glusterfs), - 'hostPath': toJson_HostPathVolumeSource(obj.hostPath), - 'iscsi': toJson_IscsiPersistentVolumeSource(obj.iscsi), - 'local': toJson_LocalVolumeSource(obj.local), - 'mountOptions': obj.mountOptions?.map(y => y), - 'nfs': toJson_NfsVolumeSource(obj.nfs), - 'nodeAffinity': toJson_VolumeNodeAffinity(obj.nodeAffinity), - 'persistentVolumeReclaimPolicy': obj.persistentVolumeReclaimPolicy, - 'photonPersistentDisk': toJson_PhotonPersistentDiskVolumeSource(obj.photonPersistentDisk), - 'portworxVolume': toJson_PortworxVolumeSource(obj.portworxVolume), - 'quobyte': toJson_QuobyteVolumeSource(obj.quobyte), - 'rbd': toJson_RbdPersistentVolumeSource(obj.rbd), - 'scaleIO': toJson_ScaleIoPersistentVolumeSource(obj.scaleIo), - 'storageClassName': obj.storageClassName, - 'storageos': toJson_StorageOsPersistentVolumeSource(obj.storageos), - 'volumeMode': obj.volumeMode, - 'vsphereVolume': toJson_VsphereVirtualDiskVolumeSource(obj.vsphereVolume), - }; - // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); +export function toJson_PersistentVolumeSpec( + obj: PersistentVolumeSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } + const result = { + accessModes: obj.accessModes?.map((y) => y), + awsElasticBlockStore: toJson_AwsElasticBlockStoreVolumeSource( + obj.awsElasticBlockStore + ), + azureDisk: toJson_AzureDiskVolumeSource(obj.azureDisk), + azureFile: toJson_AzureFilePersistentVolumeSource(obj.azureFile), + capacity: + obj.capacity === undefined + ? undefined + : Object.entries(obj.capacity).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), + cephfs: toJson_CephFsPersistentVolumeSource(obj.cephfs), + cinder: toJson_CinderPersistentVolumeSource(obj.cinder), + claimRef: toJson_ObjectReference(obj.claimRef), + csi: toJson_CsiPersistentVolumeSource(obj.csi), + fc: toJson_FcVolumeSource(obj.fc), + flexVolume: toJson_FlexPersistentVolumeSource(obj.flexVolume), + flocker: toJson_FlockerVolumeSource(obj.flocker), + gcePersistentDisk: toJson_GcePersistentDiskVolumeSource( + obj.gcePersistentDisk + ), + glusterfs: toJson_GlusterfsPersistentVolumeSource(obj.glusterfs), + hostPath: toJson_HostPathVolumeSource(obj.hostPath), + iscsi: toJson_IscsiPersistentVolumeSource(obj.iscsi), + local: toJson_LocalVolumeSource(obj.local), + mountOptions: obj.mountOptions?.map((y) => y), + nfs: toJson_NfsVolumeSource(obj.nfs), + nodeAffinity: toJson_VolumeNodeAffinity(obj.nodeAffinity), + persistentVolumeReclaimPolicy: obj.persistentVolumeReclaimPolicy, + photonPersistentDisk: toJson_PhotonPersistentDiskVolumeSource( + obj.photonPersistentDisk + ), + portworxVolume: toJson_PortworxVolumeSource(obj.portworxVolume), + quobyte: toJson_QuobyteVolumeSource(obj.quobyte), + rbd: toJson_RbdPersistentVolumeSource(obj.rbd), + scaleIO: toJson_ScaleIoPersistentVolumeSource(obj.scaleIo), + storageClassName: obj.storageClassName, + storageos: toJson_StorageOsPersistentVolumeSource(obj.storageos), + volumeMode: obj.volumeMode, + vsphereVolume: toJson_VsphereVirtualDiskVolumeSource(obj.vsphereVolume), + }; + // filter undefined values + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -20294,26 +22434,32 @@ export interface PersistentVolumeClaimSpec { * @schema io.k8s.api.core.v1.PersistentVolumeClaimSpec#volumeName */ readonly volumeName?: string; - } /** * Converts an object of type 'PersistentVolumeClaimSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PersistentVolumeClaimSpec(obj: PersistentVolumeClaimSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PersistentVolumeClaimSpec( + obj: PersistentVolumeClaimSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'accessModes': obj.accessModes?.map(y => y), - 'dataSource': toJson_TypedLocalObjectReference(obj.dataSource), - 'resources': toJson_ResourceRequirements(obj.resources), - 'selector': toJson_LabelSelector(obj.selector), - 'storageClassName': obj.storageClassName, - 'volumeMode': obj.volumeMode, - 'volumeName': obj.volumeName, + accessModes: obj.accessModes?.map((y) => y), + dataSource: toJson_TypedLocalObjectReference(obj.dataSource), + resources: toJson_ResourceRequirements(obj.resources), + selector: toJson_LabelSelector(obj.selector), + storageClassName: obj.storageClassName, + volumeMode: obj.volumeMode, + volumeName: obj.volumeName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -20578,54 +22724,78 @@ export interface PodSpec { * @schema io.k8s.api.core.v1.PodSpec#volumes */ readonly volumes?: Volume[]; - } /** * Converts an object of type 'PodSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodSpec(obj: PodSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } - const result = { - 'activeDeadlineSeconds': obj.activeDeadlineSeconds, - 'affinity': toJson_Affinity(obj.affinity), - 'automountServiceAccountToken': obj.automountServiceAccountToken, - 'containers': obj.containers?.map(y => toJson_Container(y)), - 'dnsConfig': toJson_PodDnsConfig(obj.dnsConfig), - 'dnsPolicy': obj.dnsPolicy, - 'enableServiceLinks': obj.enableServiceLinks, - 'ephemeralContainers': obj.ephemeralContainers?.map(y => toJson_EphemeralContainer(y)), - 'hostAliases': obj.hostAliases?.map(y => toJson_HostAlias(y)), - 'hostIPC': obj.hostIpc, - 'hostNetwork': obj.hostNetwork, - 'hostPID': obj.hostPid, - 'hostname': obj.hostname, - 'imagePullSecrets': obj.imagePullSecrets?.map(y => toJson_LocalObjectReference(y)), - 'initContainers': obj.initContainers?.map(y => toJson_Container(y)), - 'nodeName': obj.nodeName, - 'nodeSelector': ((obj.nodeSelector) === undefined) ? undefined : (Object.entries(obj.nodeSelector).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'overhead': ((obj.overhead) === undefined) ? undefined : (Object.entries(obj.overhead).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), - 'preemptionPolicy': obj.preemptionPolicy, - 'priority': obj.priority, - 'priorityClassName': obj.priorityClassName, - 'readinessGates': obj.readinessGates?.map(y => toJson_PodReadinessGate(y)), - 'restartPolicy': obj.restartPolicy, - 'runtimeClassName': obj.runtimeClassName, - 'schedulerName': obj.schedulerName, - 'securityContext': toJson_PodSecurityContext(obj.securityContext), - 'serviceAccount': obj.serviceAccount, - 'serviceAccountName': obj.serviceAccountName, - 'setHostnameAsFQDN': obj.setHostnameAsFqdn, - 'shareProcessNamespace': obj.shareProcessNamespace, - 'subdomain': obj.subdomain, - 'terminationGracePeriodSeconds': obj.terminationGracePeriodSeconds, - 'tolerations': obj.tolerations?.map(y => toJson_Toleration(y)), - 'topologySpreadConstraints': obj.topologySpreadConstraints?.map(y => toJson_TopologySpreadConstraint(y)), - 'volumes': obj.volumes?.map(y => toJson_Volume(y)), - }; - // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); +export function toJson_PodSpec( + obj: PodSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } + const result = { + activeDeadlineSeconds: obj.activeDeadlineSeconds, + affinity: toJson_Affinity(obj.affinity), + automountServiceAccountToken: obj.automountServiceAccountToken, + containers: obj.containers?.map((y) => toJson_Container(y)), + dnsConfig: toJson_PodDnsConfig(obj.dnsConfig), + dnsPolicy: obj.dnsPolicy, + enableServiceLinks: obj.enableServiceLinks, + ephemeralContainers: obj.ephemeralContainers?.map((y) => + toJson_EphemeralContainer(y) + ), + hostAliases: obj.hostAliases?.map((y) => toJson_HostAlias(y)), + hostIPC: obj.hostIpc, + hostNetwork: obj.hostNetwork, + hostPID: obj.hostPid, + hostname: obj.hostname, + imagePullSecrets: obj.imagePullSecrets?.map((y) => + toJson_LocalObjectReference(y) + ), + initContainers: obj.initContainers?.map((y) => toJson_Container(y)), + nodeName: obj.nodeName, + nodeSelector: + obj.nodeSelector === undefined + ? undefined + : Object.entries(obj.nodeSelector).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + overhead: + obj.overhead === undefined + ? undefined + : Object.entries(obj.overhead).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), + preemptionPolicy: obj.preemptionPolicy, + priority: obj.priority, + priorityClassName: obj.priorityClassName, + readinessGates: obj.readinessGates?.map((y) => toJson_PodReadinessGate(y)), + restartPolicy: obj.restartPolicy, + runtimeClassName: obj.runtimeClassName, + schedulerName: obj.schedulerName, + securityContext: toJson_PodSecurityContext(obj.securityContext), + serviceAccount: obj.serviceAccount, + serviceAccountName: obj.serviceAccountName, + setHostnameAsFQDN: obj.setHostnameAsFqdn, + shareProcessNamespace: obj.shareProcessNamespace, + subdomain: obj.subdomain, + terminationGracePeriodSeconds: obj.terminationGracePeriodSeconds, + tolerations: obj.tolerations?.map((y) => toJson_Toleration(y)), + topologySpreadConstraints: obj.topologySpreadConstraints?.map((y) => + toJson_TopologySpreadConstraint(y) + ), + volumes: obj.volumes?.map((y) => toJson_Volume(y)), + }; + // filter undefined values + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -20648,21 +22818,27 @@ export interface PodTemplateSpec { * @schema io.k8s.api.core.v1.PodTemplateSpec#spec */ readonly spec?: PodSpec; - } /** * Converts an object of type 'PodTemplateSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodTemplateSpec(obj: PodTemplateSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodTemplateSpec( + obj: PodTemplateSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_PodSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_PodSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -20701,23 +22877,35 @@ export interface ReplicationControllerSpec { * @schema io.k8s.api.core.v1.ReplicationControllerSpec#template */ readonly template?: PodTemplateSpec; - } /** * Converts an object of type 'ReplicationControllerSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ReplicationControllerSpec(obj: ReplicationControllerSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ReplicationControllerSpec( + obj: ReplicationControllerSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'minReadySeconds': obj.minReadySeconds, - 'replicas': obj.replicas, - 'selector': ((obj.selector) === undefined) ? undefined : (Object.entries(obj.selector).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'template': toJson_PodTemplateSpec(obj.template), + minReadySeconds: obj.minReadySeconds, + replicas: obj.replicas, + selector: + obj.selector === undefined + ? undefined + : Object.entries(obj.selector).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + template: toJson_PodTemplateSpec(obj.template), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -20747,22 +22935,34 @@ export interface ResourceQuotaSpec { * @schema io.k8s.api.core.v1.ResourceQuotaSpec#scopes */ readonly scopes?: string[]; - } /** * Converts an object of type 'ResourceQuotaSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ResourceQuotaSpec(obj: ResourceQuotaSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ResourceQuotaSpec( + obj: ResourceQuotaSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'hard': ((obj.hard) === undefined) ? undefined : (Object.entries(obj.hard).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), - 'scopeSelector': toJson_ScopeSelector(obj.scopeSelector), - 'scopes': obj.scopes?.map(y => y), + hard: + obj.hard === undefined + ? undefined + : Object.entries(obj.hard).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), + scopeSelector: toJson_ScopeSelector(obj.scopeSelector), + scopes: obj.scopes?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -20918,39 +23118,53 @@ export interface ServiceSpec { * @schema io.k8s.api.core.v1.ServiceSpec#type */ readonly type?: string; - } /** * Converts an object of type 'ServiceSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ServiceSpec(obj: ServiceSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } - const result = { - 'allocateLoadBalancerNodePorts': obj.allocateLoadBalancerNodePorts, - 'clusterIP': obj.clusterIp, - 'clusterIPs': obj.clusterIPs?.map(y => y), - 'externalIPs': obj.externalIPs?.map(y => y), - 'externalName': obj.externalName, - 'externalTrafficPolicy': obj.externalTrafficPolicy, - 'healthCheckNodePort': obj.healthCheckNodePort, - 'internalTrafficPolicy': obj.internalTrafficPolicy, - 'ipFamilies': obj.ipFamilies?.map(y => y), - 'ipFamilyPolicy': obj.ipFamilyPolicy, - 'loadBalancerClass': obj.loadBalancerClass, - 'loadBalancerIP': obj.loadBalancerIp, - 'loadBalancerSourceRanges': obj.loadBalancerSourceRanges?.map(y => y), - 'ports': obj.ports?.map(y => toJson_ServicePort(y)), - 'publishNotReadyAddresses': obj.publishNotReadyAddresses, - 'selector': ((obj.selector) === undefined) ? undefined : (Object.entries(obj.selector).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'sessionAffinity': obj.sessionAffinity, - 'sessionAffinityConfig': toJson_SessionAffinityConfig(obj.sessionAffinityConfig), - 'topologyKeys': obj.topologyKeys?.map(y => y), - 'type': obj.type, - }; - // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); +export function toJson_ServiceSpec( + obj: ServiceSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } + const result = { + allocateLoadBalancerNodePorts: obj.allocateLoadBalancerNodePorts, + clusterIP: obj.clusterIp, + clusterIPs: obj.clusterIPs?.map((y) => y), + externalIPs: obj.externalIPs?.map((y) => y), + externalName: obj.externalName, + externalTrafficPolicy: obj.externalTrafficPolicy, + healthCheckNodePort: obj.healthCheckNodePort, + internalTrafficPolicy: obj.internalTrafficPolicy, + ipFamilies: obj.ipFamilies?.map((y) => y), + ipFamilyPolicy: obj.ipFamilyPolicy, + loadBalancerClass: obj.loadBalancerClass, + loadBalancerIP: obj.loadBalancerIp, + loadBalancerSourceRanges: obj.loadBalancerSourceRanges?.map((y) => y), + ports: obj.ports?.map((y) => toJson_ServicePort(y)), + publishNotReadyAddresses: obj.publishNotReadyAddresses, + selector: + obj.selector === undefined + ? undefined + : Object.entries(obj.selector).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + sessionAffinity: obj.sessionAffinity, + sessionAffinityConfig: toJson_SessionAffinityConfig( + obj.sessionAffinityConfig + ), + topologyKeys: obj.topologyKeys?.map((y) => y), + type: obj.type, + }; + // filter undefined values + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -20966,20 +23180,26 @@ export interface LocalObjectReference { * @schema io.k8s.api.core.v1.LocalObjectReference#name */ readonly name?: string; - } /** * Converts an object of type 'LocalObjectReference' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LocalObjectReference(obj: LocalObjectReference | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_LocalObjectReference( + obj: LocalObjectReference | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21044,27 +23264,39 @@ export interface Endpoint { * @schema io.k8s.api.discovery.v1.Endpoint#zone */ readonly zone?: string; - } /** * Converts an object of type 'Endpoint' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Endpoint(obj: Endpoint | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Endpoint( + obj: Endpoint | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'addresses': obj.addresses?.map(y => y), - 'conditions': toJson_EndpointConditions(obj.conditions), - 'deprecatedTopology': ((obj.deprecatedTopology) === undefined) ? undefined : (Object.entries(obj.deprecatedTopology).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'hints': toJson_EndpointHints(obj.hints), - 'hostname': obj.hostname, - 'nodeName': obj.nodeName, - 'targetRef': toJson_ObjectReference(obj.targetRef), - 'zone': obj.zone, + addresses: obj.addresses?.map((y) => y), + conditions: toJson_EndpointConditions(obj.conditions), + deprecatedTopology: + obj.deprecatedTopology === undefined + ? undefined + : Object.entries(obj.deprecatedTopology).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + hints: toJson_EndpointHints(obj.hints), + hostname: obj.hostname, + nodeName: obj.nodeName, + targetRef: toJson_ObjectReference(obj.targetRef), + zone: obj.zone, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21102,23 +23334,29 @@ export interface EndpointPort { * @schema io.k8s.api.core.v1.EndpointPort#protocol */ readonly protocol?: string; - } /** * Converts an object of type 'EndpointPort' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EndpointPort(obj: EndpointPort | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EndpointPort( + obj: EndpointPort | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'appProtocol': obj.appProtocol, - 'name': obj.name, - 'port': obj.port, - 'protocol': obj.protocol, + appProtocol: obj.appProtocol, + name: obj.name, + port: obj.port, + protocol: obj.protocol, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21183,26 +23421,38 @@ export interface EndpointV1Beta1 { * @schema io.k8s.api.discovery.v1beta1.Endpoint#topology */ readonly topology?: { [key: string]: string }; - } /** * Converts an object of type 'EndpointV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EndpointV1Beta1(obj: EndpointV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EndpointV1Beta1( + obj: EndpointV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'addresses': obj.addresses?.map(y => y), - 'conditions': toJson_EndpointConditionsV1Beta1(obj.conditions), - 'hints': toJson_EndpointHintsV1Beta1(obj.hints), - 'hostname': obj.hostname, - 'nodeName': obj.nodeName, - 'targetRef': toJson_ObjectReference(obj.targetRef), - 'topology': ((obj.topology) === undefined) ? undefined : (Object.entries(obj.topology).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), + addresses: obj.addresses?.map((y) => y), + conditions: toJson_EndpointConditionsV1Beta1(obj.conditions), + hints: toJson_EndpointHintsV1Beta1(obj.hints), + hostname: obj.hostname, + nodeName: obj.nodeName, + targetRef: toJson_ObjectReference(obj.targetRef), + topology: + obj.topology === undefined + ? undefined + : Object.entries(obj.topology).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21241,23 +23491,29 @@ export interface EndpointPortV1Beta1 { * @schema io.k8s.api.discovery.v1beta1.EndpointPort#protocol */ readonly protocol?: string; - } /** * Converts an object of type 'EndpointPortV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EndpointPortV1Beta1(obj: EndpointPortV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EndpointPortV1Beta1( + obj: EndpointPortV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'appProtocol': obj.appProtocol, - 'name': obj.name, - 'port': obj.port, - 'protocol': obj.protocol, + appProtocol: obj.appProtocol, + name: obj.name, + port: obj.port, + protocol: obj.protocol, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21280,21 +23536,27 @@ export interface EventSeriesV1Beta1 { * @schema io.k8s.api.events.v1beta1.EventSeries#lastObservedTime */ readonly lastObservedTime: Date; - } /** * Converts an object of type 'EventSeriesV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EventSeriesV1Beta1(obj: EventSeriesV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EventSeriesV1Beta1( + obj: EventSeriesV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'count': obj.count, - 'lastObservedTime': obj.lastObservedTime?.toISOString(), + count: obj.count, + lastObservedTime: obj.lastObservedTime?.toISOString(), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21331,23 +23593,29 @@ export interface IngressSpecV1Beta1 { * @schema io.k8s.api.networking.v1beta1.IngressSpec#tls */ readonly tls?: IngressTlsv1Beta1[]; - } /** * Converts an object of type 'IngressSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressSpecV1Beta1(obj: IngressSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressSpecV1Beta1( + obj: IngressSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'backend': toJson_IngressBackendV1Beta1(obj.backend), - 'ingressClassName': obj.ingressClassName, - 'rules': obj.rules?.map(y => toJson_IngressRuleV1Beta1(y)), - 'tls': obj.tls?.map(y => toJson_IngressTlsv1Beta1(y)), + backend: toJson_IngressBackendV1Beta1(obj.backend), + ingressClassName: obj.ingressClassName, + rules: obj.rules?.map((y) => toJson_IngressRuleV1Beta1(y)), + tls: obj.tls?.map((y) => toJson_IngressTlsv1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21384,23 +23652,34 @@ export interface FlowSchemaSpecV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.FlowSchemaSpec#rules */ readonly rules?: PolicyRulesWithSubjectsV1Beta1[]; - } /** * Converts an object of type 'FlowSchemaSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_FlowSchemaSpecV1Beta1(obj: FlowSchemaSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_FlowSchemaSpecV1Beta1( + obj: FlowSchemaSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'distinguisherMethod': toJson_FlowDistinguisherMethodV1Beta1(obj.distinguisherMethod), - 'matchingPrecedence': obj.matchingPrecedence, - 'priorityLevelConfiguration': toJson_PriorityLevelConfigurationReferenceV1Beta1(obj.priorityLevelConfiguration), - 'rules': obj.rules?.map(y => toJson_PolicyRulesWithSubjectsV1Beta1(y)), + distinguisherMethod: toJson_FlowDistinguisherMethodV1Beta1( + obj.distinguisherMethod + ), + matchingPrecedence: obj.matchingPrecedence, + priorityLevelConfiguration: + toJson_PriorityLevelConfigurationReferenceV1Beta1( + obj.priorityLevelConfiguration + ), + rules: obj.rules?.map((y) => toJson_PolicyRulesWithSubjectsV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21423,21 +23702,27 @@ export interface PriorityLevelConfigurationSpecV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.PriorityLevelConfigurationSpec#type */ readonly type: string; - } /** * Converts an object of type 'PriorityLevelConfigurationSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PriorityLevelConfigurationSpecV1Beta1(obj: PriorityLevelConfigurationSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PriorityLevelConfigurationSpecV1Beta1( + obj: PriorityLevelConfigurationSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'limited': toJson_LimitedPriorityLevelConfigurationV1Beta1(obj.limited), - 'type': obj.type, + limited: toJson_LimitedPriorityLevelConfigurationV1Beta1(obj.limited), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21474,23 +23759,29 @@ export interface IngressSpec { * @schema io.k8s.api.networking.v1.IngressSpec#tls */ readonly tls?: IngressTls[]; - } /** * Converts an object of type 'IngressSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressSpec(obj: IngressSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressSpec( + obj: IngressSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'defaultBackend': toJson_IngressBackend(obj.defaultBackend), - 'ingressClassName': obj.ingressClassName, - 'rules': obj.rules?.map(y => toJson_IngressRule(y)), - 'tls': obj.tls?.map(y => toJson_IngressTls(y)), + defaultBackend: toJson_IngressBackend(obj.defaultBackend), + ingressClassName: obj.ingressClassName, + rules: obj.rules?.map((y) => toJson_IngressRule(y)), + tls: obj.tls?.map((y) => toJson_IngressTls(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21513,21 +23804,27 @@ export interface IngressClassSpec { * @schema io.k8s.api.networking.v1.IngressClassSpec#parameters */ readonly parameters?: IngressClassParametersReference; - } /** * Converts an object of type 'IngressClassSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressClassSpec(obj: IngressClassSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressClassSpec( + obj: IngressClassSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'controller': obj.controller, - 'parameters': toJson_IngressClassParametersReference(obj.parameters), + controller: obj.controller, + parameters: toJson_IngressClassParametersReference(obj.parameters), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21564,23 +23861,29 @@ export interface NetworkPolicySpec { * @schema io.k8s.api.networking.v1.NetworkPolicySpec#policyTypes */ readonly policyTypes?: string[]; - } /** * Converts an object of type 'NetworkPolicySpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NetworkPolicySpec(obj: NetworkPolicySpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NetworkPolicySpec( + obj: NetworkPolicySpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'egress': obj.egress?.map(y => toJson_NetworkPolicyEgressRule(y)), - 'ingress': obj.ingress?.map(y => toJson_NetworkPolicyIngressRule(y)), - 'podSelector': toJson_LabelSelector(obj.podSelector), - 'policyTypes': obj.policyTypes?.map(y => y), + egress: obj.egress?.map((y) => toJson_NetworkPolicyEgressRule(y)), + ingress: obj.ingress?.map((y) => toJson_NetworkPolicyIngressRule(y)), + podSelector: toJson_LabelSelector(obj.podSelector), + policyTypes: obj.policyTypes?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21603,21 +23906,27 @@ export interface IngressClassSpecV1Beta1 { * @schema io.k8s.api.networking.v1beta1.IngressClassSpec#parameters */ readonly parameters?: IngressClassParametersReferenceV1Beta1; - } /** * Converts an object of type 'IngressClassSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressClassSpecV1Beta1(obj: IngressClassSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressClassSpecV1Beta1( + obj: IngressClassSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'controller': obj.controller, - 'parameters': toJson_IngressClassParametersReferenceV1Beta1(obj.parameters), + controller: obj.controller, + parameters: toJson_IngressClassParametersReferenceV1Beta1(obj.parameters), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21633,20 +23942,32 @@ export interface Overhead { * @schema io.k8s.api.node.v1.Overhead#podFixed */ readonly podFixed?: { [key: string]: Quantity }; - } /** * Converts an object of type 'Overhead' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Overhead(obj: Overhead | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Overhead( + obj: Overhead | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'podFixed': ((obj.podFixed) === undefined) ? undefined : (Object.entries(obj.podFixed).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), + podFixed: + obj.podFixed === undefined + ? undefined + : Object.entries(obj.podFixed).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21669,21 +23990,33 @@ export interface Scheduling { * @schema io.k8s.api.node.v1.Scheduling#tolerations */ readonly tolerations?: Toleration[]; - } /** * Converts an object of type 'Scheduling' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Scheduling(obj: Scheduling | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Scheduling( + obj: Scheduling | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nodeSelector': ((obj.nodeSelector) === undefined) ? undefined : (Object.entries(obj.nodeSelector).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'tolerations': obj.tolerations?.map(y => toJson_Toleration(y)), + nodeSelector: + obj.nodeSelector === undefined + ? undefined + : Object.entries(obj.nodeSelector).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + tolerations: obj.tolerations?.map((y) => toJson_Toleration(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21713,22 +24046,28 @@ export interface RuntimeClassSpecV1Alpha1 { * @schema io.k8s.api.node.v1alpha1.RuntimeClassSpec#scheduling */ readonly scheduling?: SchedulingV1Alpha1; - } /** * Converts an object of type 'RuntimeClassSpecV1Alpha1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RuntimeClassSpecV1Alpha1(obj: RuntimeClassSpecV1Alpha1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RuntimeClassSpecV1Alpha1( + obj: RuntimeClassSpecV1Alpha1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'overhead': toJson_OverheadV1Alpha1(obj.overhead), - 'runtimeHandler': obj.runtimeHandler, - 'scheduling': toJson_SchedulingV1Alpha1(obj.scheduling), + overhead: toJson_OverheadV1Alpha1(obj.overhead), + runtimeHandler: obj.runtimeHandler, + scheduling: toJson_SchedulingV1Alpha1(obj.scheduling), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21744,20 +24083,32 @@ export interface OverheadV1Beta1 { * @schema io.k8s.api.node.v1beta1.Overhead#podFixed */ readonly podFixed?: { [key: string]: Quantity }; - } /** * Converts an object of type 'OverheadV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_OverheadV1Beta1(obj: OverheadV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_OverheadV1Beta1( + obj: OverheadV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'podFixed': ((obj.podFixed) === undefined) ? undefined : (Object.entries(obj.podFixed).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), + podFixed: + obj.podFixed === undefined + ? undefined + : Object.entries(obj.podFixed).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21780,21 +24131,33 @@ export interface SchedulingV1Beta1 { * @schema io.k8s.api.node.v1beta1.Scheduling#tolerations */ readonly tolerations?: Toleration[]; - } /** * Converts an object of type 'SchedulingV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SchedulingV1Beta1(obj: SchedulingV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SchedulingV1Beta1( + obj: SchedulingV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nodeSelector': ((obj.nodeSelector) === undefined) ? undefined : (Object.entries(obj.nodeSelector).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'tolerations': obj.tolerations?.map(y => toJson_Toleration(y)), + nodeSelector: + obj.nodeSelector === undefined + ? undefined + : Object.entries(obj.nodeSelector).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + tolerations: obj.tolerations?.map((y) => toJson_Toleration(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21824,22 +24187,28 @@ export interface PodDisruptionBudgetSpec { * @schema io.k8s.api.policy.v1.PodDisruptionBudgetSpec#selector */ readonly selector?: LabelSelector; - } /** * Converts an object of type 'PodDisruptionBudgetSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodDisruptionBudgetSpec(obj: PodDisruptionBudgetSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodDisruptionBudgetSpec( + obj: PodDisruptionBudgetSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'maxUnavailable': obj.maxUnavailable?.value, - 'minAvailable': obj.minAvailable?.value, - 'selector': toJson_LabelSelector(obj.selector), + maxUnavailable: obj.maxUnavailable?.value, + minAvailable: obj.minAvailable?.value, + selector: toJson_LabelSelector(obj.selector), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21898,26 +24267,32 @@ export interface DeleteOptions { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.DeleteOptions#propagationPolicy */ readonly propagationPolicy?: string; - } /** * Converts an object of type 'DeleteOptions' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_DeleteOptions(obj: DeleteOptions | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_DeleteOptions( + obj: DeleteOptions | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'dryRun': obj.dryRun?.map(y => y), - 'gracePeriodSeconds': obj.gracePeriodSeconds, - 'kind': obj.kind, - 'orphanDependents': obj.orphanDependents, - 'preconditions': toJson_Preconditions(obj.preconditions), - 'propagationPolicy': obj.propagationPolicy, + apiVersion: obj.apiVersion, + dryRun: obj.dryRun?.map((y) => y), + gracePeriodSeconds: obj.gracePeriodSeconds, + kind: obj.kind, + orphanDependents: obj.orphanDependents, + preconditions: toJson_Preconditions(obj.preconditions), + propagationPolicy: obj.propagationPolicy, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -21947,22 +24322,28 @@ export interface PodDisruptionBudgetSpecV1Beta1 { * @schema io.k8s.api.policy.v1beta1.PodDisruptionBudgetSpec#selector */ readonly selector?: LabelSelector; - } /** * Converts an object of type 'PodDisruptionBudgetSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodDisruptionBudgetSpecV1Beta1(obj: PodDisruptionBudgetSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodDisruptionBudgetSpecV1Beta1( + obj: PodDisruptionBudgetSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'maxUnavailable': obj.maxUnavailable?.value, - 'minAvailable': obj.minAvailable?.value, - 'selector': toJson_LabelSelector(obj.selector), + maxUnavailable: obj.maxUnavailable?.value, + minAvailable: obj.minAvailable?.value, + selector: toJson_LabelSelector(obj.selector), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22143,43 +24524,57 @@ export interface PodSecurityPolicySpecV1Beta1 { * @schema io.k8s.api.policy.v1beta1.PodSecurityPolicySpec#volumes */ readonly volumes?: string[]; - } /** * Converts an object of type 'PodSecurityPolicySpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodSecurityPolicySpecV1Beta1(obj: PodSecurityPolicySpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } - const result = { - 'allowPrivilegeEscalation': obj.allowPrivilegeEscalation, - 'allowedCSIDrivers': obj.allowedCsiDrivers?.map(y => toJson_AllowedCsiDriverV1Beta1(y)), - 'allowedCapabilities': obj.allowedCapabilities?.map(y => y), - 'allowedFlexVolumes': obj.allowedFlexVolumes?.map(y => toJson_AllowedFlexVolumeV1Beta1(y)), - 'allowedHostPaths': obj.allowedHostPaths?.map(y => toJson_AllowedHostPathV1Beta1(y)), - 'allowedProcMountTypes': obj.allowedProcMountTypes?.map(y => y), - 'allowedUnsafeSysctls': obj.allowedUnsafeSysctls?.map(y => y), - 'defaultAddCapabilities': obj.defaultAddCapabilities?.map(y => y), - 'defaultAllowPrivilegeEscalation': obj.defaultAllowPrivilegeEscalation, - 'forbiddenSysctls': obj.forbiddenSysctls?.map(y => y), - 'fsGroup': toJson_FsGroupStrategyOptionsV1Beta1(obj.fsGroup), - 'hostIPC': obj.hostIpc, - 'hostNetwork': obj.hostNetwork, - 'hostPID': obj.hostPid, - 'hostPorts': obj.hostPorts?.map(y => toJson_HostPortRangeV1Beta1(y)), - 'privileged': obj.privileged, - 'readOnlyRootFilesystem': obj.readOnlyRootFilesystem, - 'requiredDropCapabilities': obj.requiredDropCapabilities?.map(y => y), - 'runAsGroup': toJson_RunAsGroupStrategyOptionsV1Beta1(obj.runAsGroup), - 'runAsUser': toJson_RunAsUserStrategyOptionsV1Beta1(obj.runAsUser), - 'runtimeClass': toJson_RuntimeClassStrategyOptionsV1Beta1(obj.runtimeClass), - 'seLinux': toJson_SeLinuxStrategyOptionsV1Beta1(obj.seLinux), - 'supplementalGroups': toJson_SupplementalGroupsStrategyOptionsV1Beta1(obj.supplementalGroups), - 'volumes': obj.volumes?.map(y => y), - }; - // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); +export function toJson_PodSecurityPolicySpecV1Beta1( + obj: PodSecurityPolicySpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } + const result = { + allowPrivilegeEscalation: obj.allowPrivilegeEscalation, + allowedCSIDrivers: obj.allowedCsiDrivers?.map((y) => + toJson_AllowedCsiDriverV1Beta1(y) + ), + allowedCapabilities: obj.allowedCapabilities?.map((y) => y), + allowedFlexVolumes: obj.allowedFlexVolumes?.map((y) => + toJson_AllowedFlexVolumeV1Beta1(y) + ), + allowedHostPaths: obj.allowedHostPaths?.map((y) => + toJson_AllowedHostPathV1Beta1(y) + ), + allowedProcMountTypes: obj.allowedProcMountTypes?.map((y) => y), + allowedUnsafeSysctls: obj.allowedUnsafeSysctls?.map((y) => y), + defaultAddCapabilities: obj.defaultAddCapabilities?.map((y) => y), + defaultAllowPrivilegeEscalation: obj.defaultAllowPrivilegeEscalation, + forbiddenSysctls: obj.forbiddenSysctls?.map((y) => y), + fsGroup: toJson_FsGroupStrategyOptionsV1Beta1(obj.fsGroup), + hostIPC: obj.hostIpc, + hostNetwork: obj.hostNetwork, + hostPID: obj.hostPid, + hostPorts: obj.hostPorts?.map((y) => toJson_HostPortRangeV1Beta1(y)), + privileged: obj.privileged, + readOnlyRootFilesystem: obj.readOnlyRootFilesystem, + requiredDropCapabilities: obj.requiredDropCapabilities?.map((y) => y), + runAsGroup: toJson_RunAsGroupStrategyOptionsV1Beta1(obj.runAsGroup), + runAsUser: toJson_RunAsUserStrategyOptionsV1Beta1(obj.runAsUser), + runtimeClass: toJson_RuntimeClassStrategyOptionsV1Beta1(obj.runtimeClass), + seLinux: toJson_SeLinuxStrategyOptionsV1Beta1(obj.seLinux), + supplementalGroups: toJson_SupplementalGroupsStrategyOptionsV1Beta1( + obj.supplementalGroups + ), + volumes: obj.volumes?.map((y) => y), + }; + // filter undefined values + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22195,20 +24590,28 @@ export interface AggregationRule { * @schema io.k8s.api.rbac.v1.AggregationRule#clusterRoleSelectors */ readonly clusterRoleSelectors?: LabelSelector[]; - } /** * Converts an object of type 'AggregationRule' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AggregationRule(obj: AggregationRule | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AggregationRule( + obj: AggregationRule | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'clusterRoleSelectors': obj.clusterRoleSelectors?.map(y => toJson_LabelSelector(y)), + clusterRoleSelectors: obj.clusterRoleSelectors?.map((y) => + toJson_LabelSelector(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22252,24 +24655,30 @@ export interface PolicyRule { * @schema io.k8s.api.rbac.v1.PolicyRule#verbs */ readonly verbs: string[]; - } /** * Converts an object of type 'PolicyRule' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PolicyRule(obj: PolicyRule | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PolicyRule( + obj: PolicyRule | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroups': obj.apiGroups?.map(y => y), - 'nonResourceURLs': obj.nonResourceUrLs?.map(y => y), - 'resourceNames': obj.resourceNames?.map(y => y), - 'resources': obj.resources?.map(y => y), - 'verbs': obj.verbs?.map(y => y), + apiGroups: obj.apiGroups?.map((y) => y), + nonResourceURLs: obj.nonResourceUrLs?.map((y) => y), + resourceNames: obj.resourceNames?.map((y) => y), + resources: obj.resources?.map((y) => y), + verbs: obj.verbs?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22299,22 +24708,28 @@ export interface RoleRef { * @schema io.k8s.api.rbac.v1.RoleRef#name */ readonly name: string; - } /** * Converts an object of type 'RoleRef' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RoleRef(obj: RoleRef | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RoleRef( + obj: RoleRef | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroup': obj.apiGroup, - 'kind': obj.kind, - 'name': obj.name, + apiGroup: obj.apiGroup, + kind: obj.kind, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22352,23 +24767,29 @@ export interface Subject { * @schema io.k8s.api.rbac.v1.Subject#namespace */ readonly namespace?: string; - } /** * Converts an object of type 'Subject' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Subject(obj: Subject | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Subject( + obj: Subject | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroup': obj.apiGroup, - 'kind': obj.kind, - 'name': obj.name, - 'namespace': obj.namespace, + apiGroup: obj.apiGroup, + kind: obj.kind, + name: obj.name, + namespace: obj.namespace, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22384,20 +24805,28 @@ export interface AggregationRuleV1Alpha1 { * @schema io.k8s.api.rbac.v1alpha1.AggregationRule#clusterRoleSelectors */ readonly clusterRoleSelectors?: LabelSelector[]; - } /** * Converts an object of type 'AggregationRuleV1Alpha1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AggregationRuleV1Alpha1(obj: AggregationRuleV1Alpha1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AggregationRuleV1Alpha1( + obj: AggregationRuleV1Alpha1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'clusterRoleSelectors': obj.clusterRoleSelectors?.map(y => toJson_LabelSelector(y)), + clusterRoleSelectors: obj.clusterRoleSelectors?.map((y) => + toJson_LabelSelector(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22441,24 +24870,30 @@ export interface PolicyRuleV1Alpha1 { * @schema io.k8s.api.rbac.v1alpha1.PolicyRule#verbs */ readonly verbs: string[]; - } /** * Converts an object of type 'PolicyRuleV1Alpha1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PolicyRuleV1Alpha1(obj: PolicyRuleV1Alpha1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PolicyRuleV1Alpha1( + obj: PolicyRuleV1Alpha1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroups': obj.apiGroups?.map(y => y), - 'nonResourceURLs': obj.nonResourceUrLs?.map(y => y), - 'resourceNames': obj.resourceNames?.map(y => y), - 'resources': obj.resources?.map(y => y), - 'verbs': obj.verbs?.map(y => y), + apiGroups: obj.apiGroups?.map((y) => y), + nonResourceURLs: obj.nonResourceUrLs?.map((y) => y), + resourceNames: obj.resourceNames?.map((y) => y), + resources: obj.resources?.map((y) => y), + verbs: obj.verbs?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22488,22 +24923,28 @@ export interface RoleRefV1Alpha1 { * @schema io.k8s.api.rbac.v1alpha1.RoleRef#name */ readonly name: string; - } /** * Converts an object of type 'RoleRefV1Alpha1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RoleRefV1Alpha1(obj: RoleRefV1Alpha1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RoleRefV1Alpha1( + obj: RoleRefV1Alpha1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroup': obj.apiGroup, - 'kind': obj.kind, - 'name': obj.name, + apiGroup: obj.apiGroup, + kind: obj.kind, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22541,23 +24982,29 @@ export interface SubjectV1Alpha1 { * @schema io.k8s.api.rbac.v1alpha1.Subject#namespace */ readonly namespace?: string; - } /** * Converts an object of type 'SubjectV1Alpha1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SubjectV1Alpha1(obj: SubjectV1Alpha1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SubjectV1Alpha1( + obj: SubjectV1Alpha1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'kind': obj.kind, - 'name': obj.name, - 'namespace': obj.namespace, + apiVersion: obj.apiVersion, + kind: obj.kind, + name: obj.name, + namespace: obj.namespace, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22573,20 +25020,28 @@ export interface AggregationRuleV1Beta1 { * @schema io.k8s.api.rbac.v1beta1.AggregationRule#clusterRoleSelectors */ readonly clusterRoleSelectors?: LabelSelector[]; - } /** * Converts an object of type 'AggregationRuleV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AggregationRuleV1Beta1(obj: AggregationRuleV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AggregationRuleV1Beta1( + obj: AggregationRuleV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'clusterRoleSelectors': obj.clusterRoleSelectors?.map(y => toJson_LabelSelector(y)), + clusterRoleSelectors: obj.clusterRoleSelectors?.map((y) => + toJson_LabelSelector(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22630,24 +25085,30 @@ export interface PolicyRuleV1Beta1 { * @schema io.k8s.api.rbac.v1beta1.PolicyRule#verbs */ readonly verbs: string[]; - } /** * Converts an object of type 'PolicyRuleV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PolicyRuleV1Beta1(obj: PolicyRuleV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PolicyRuleV1Beta1( + obj: PolicyRuleV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroups': obj.apiGroups?.map(y => y), - 'nonResourceURLs': obj.nonResourceUrLs?.map(y => y), - 'resourceNames': obj.resourceNames?.map(y => y), - 'resources': obj.resources?.map(y => y), - 'verbs': obj.verbs?.map(y => y), + apiGroups: obj.apiGroups?.map((y) => y), + nonResourceURLs: obj.nonResourceUrLs?.map((y) => y), + resourceNames: obj.resourceNames?.map((y) => y), + resources: obj.resources?.map((y) => y), + verbs: obj.verbs?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22677,22 +25138,28 @@ export interface RoleRefV1Beta1 { * @schema io.k8s.api.rbac.v1beta1.RoleRef#name */ readonly name: string; - } /** * Converts an object of type 'RoleRefV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RoleRefV1Beta1(obj: RoleRefV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RoleRefV1Beta1( + obj: RoleRefV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroup': obj.apiGroup, - 'kind': obj.kind, - 'name': obj.name, + apiGroup: obj.apiGroup, + kind: obj.kind, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22730,23 +25197,29 @@ export interface SubjectV1Beta1 { * @schema io.k8s.api.rbac.v1beta1.Subject#namespace */ readonly namespace?: string; - } /** * Converts an object of type 'SubjectV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SubjectV1Beta1(obj: SubjectV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SubjectV1Beta1( + obj: SubjectV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroup': obj.apiGroup, - 'kind': obj.kind, - 'name': obj.name, - 'namespace': obj.namespace, + apiGroup: obj.apiGroup, + kind: obj.kind, + name: obj.name, + namespace: obj.namespace, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22838,26 +25311,32 @@ export interface CsiDriverSpec { * @schema io.k8s.api.storage.v1.CSIDriverSpec#volumeLifecycleModes */ readonly volumeLifecycleModes?: string[]; - } /** * Converts an object of type 'CsiDriverSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CsiDriverSpec(obj: CsiDriverSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CsiDriverSpec( + obj: CsiDriverSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'attachRequired': obj.attachRequired, - 'fsGroupPolicy': obj.fsGroupPolicy, - 'podInfoOnMount': obj.podInfoOnMount, - 'requiresRepublish': obj.requiresRepublish, - 'storageCapacity': obj.storageCapacity, - 'tokenRequests': obj.tokenRequests?.map(y => toJson_TokenRequest(y)), - 'volumeLifecycleModes': obj.volumeLifecycleModes?.map(y => y), + attachRequired: obj.attachRequired, + fsGroupPolicy: obj.fsGroupPolicy, + podInfoOnMount: obj.podInfoOnMount, + requiresRepublish: obj.requiresRepublish, + storageCapacity: obj.storageCapacity, + tokenRequests: obj.tokenRequests?.map((y) => toJson_TokenRequest(y)), + volumeLifecycleModes: obj.volumeLifecycleModes?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22873,20 +25352,26 @@ export interface CsiNodeSpec { * @schema io.k8s.api.storage.v1.CSINodeSpec#drivers */ readonly drivers: CsiNodeDriver[]; - } /** * Converts an object of type 'CsiNodeSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CsiNodeSpec(obj: CsiNodeSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CsiNodeSpec( + obj: CsiNodeSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'drivers': obj.drivers?.map(y => toJson_CsiNodeDriver(y)), + drivers: obj.drivers?.map((y) => toJson_CsiNodeDriver(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22902,20 +25387,28 @@ export interface TopologySelectorTerm { * @schema io.k8s.api.core.v1.TopologySelectorTerm#matchLabelExpressions */ readonly matchLabelExpressions?: TopologySelectorLabelRequirement[]; - } /** * Converts an object of type 'TopologySelectorTerm' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TopologySelectorTerm(obj: TopologySelectorTerm | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TopologySelectorTerm( + obj: TopologySelectorTerm | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'matchLabelExpressions': obj.matchLabelExpressions?.map(y => toJson_TopologySelectorLabelRequirement(y)), + matchLabelExpressions: obj.matchLabelExpressions?.map((y) => + toJson_TopologySelectorLabelRequirement(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22945,22 +25438,28 @@ export interface VolumeAttachmentSpec { * @schema io.k8s.api.storage.v1.VolumeAttachmentSpec#source */ readonly source: VolumeAttachmentSource; - } /** * Converts an object of type 'VolumeAttachmentSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeAttachmentSpec(obj: VolumeAttachmentSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeAttachmentSpec( + obj: VolumeAttachmentSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'attacher': obj.attacher, - 'nodeName': obj.nodeName, - 'source': toJson_VolumeAttachmentSource(obj.source), + attacher: obj.attacher, + nodeName: obj.nodeName, + source: toJson_VolumeAttachmentSource(obj.source), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -22974,8 +25473,7 @@ export class Quantity { public static fromNumber(value: number): Quantity { return new Quantity(value); } - private constructor(public readonly value: any) { - } + private constructor(public readonly value: any) {} } /** @@ -22997,21 +25495,35 @@ export interface LabelSelector { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.LabelSelector#matchLabels */ readonly matchLabels?: { [key: string]: string }; - } /** * Converts an object of type 'LabelSelector' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LabelSelector(obj: LabelSelector | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_LabelSelector( + obj: LabelSelector | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'matchExpressions': obj.matchExpressions?.map(y => toJson_LabelSelectorRequirement(y)), - 'matchLabels': ((obj.matchLabels) === undefined) ? undefined : (Object.entries(obj.matchLabels).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), + matchExpressions: obj.matchExpressions?.map((y) => + toJson_LabelSelectorRequirement(y) + ), + matchLabels: + obj.matchLabels === undefined + ? undefined + : Object.entries(obj.matchLabels).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23041,22 +25553,28 @@ export interface VolumeAttachmentSpecV1Alpha1 { * @schema io.k8s.api.storage.v1alpha1.VolumeAttachmentSpec#source */ readonly source: VolumeAttachmentSourceV1Alpha1; - } /** * Converts an object of type 'VolumeAttachmentSpecV1Alpha1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeAttachmentSpecV1Alpha1(obj: VolumeAttachmentSpecV1Alpha1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeAttachmentSpecV1Alpha1( + obj: VolumeAttachmentSpecV1Alpha1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'attacher': obj.attacher, - 'nodeName': obj.nodeName, - 'source': toJson_VolumeAttachmentSourceV1Alpha1(obj.source), + attacher: obj.attacher, + nodeName: obj.nodeName, + source: toJson_VolumeAttachmentSourceV1Alpha1(obj.source), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23148,26 +25666,32 @@ export interface CsiDriverSpecV1Beta1 { * @schema io.k8s.api.storage.v1beta1.CSIDriverSpec#volumeLifecycleModes */ readonly volumeLifecycleModes?: string[]; - } /** * Converts an object of type 'CsiDriverSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CsiDriverSpecV1Beta1(obj: CsiDriverSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CsiDriverSpecV1Beta1( + obj: CsiDriverSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'attachRequired': obj.attachRequired, - 'fsGroupPolicy': obj.fsGroupPolicy, - 'podInfoOnMount': obj.podInfoOnMount, - 'requiresRepublish': obj.requiresRepublish, - 'storageCapacity': obj.storageCapacity, - 'tokenRequests': obj.tokenRequests?.map(y => toJson_TokenRequestV1Beta1(y)), - 'volumeLifecycleModes': obj.volumeLifecycleModes?.map(y => y), + attachRequired: obj.attachRequired, + fsGroupPolicy: obj.fsGroupPolicy, + podInfoOnMount: obj.podInfoOnMount, + requiresRepublish: obj.requiresRepublish, + storageCapacity: obj.storageCapacity, + tokenRequests: obj.tokenRequests?.map((y) => toJson_TokenRequestV1Beta1(y)), + volumeLifecycleModes: obj.volumeLifecycleModes?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23183,20 +25707,26 @@ export interface CsiNodeSpecV1Beta1 { * @schema io.k8s.api.storage.v1beta1.CSINodeSpec#drivers */ readonly drivers: CsiNodeDriverV1Beta1[]; - } /** * Converts an object of type 'CsiNodeSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CsiNodeSpecV1Beta1(obj: CsiNodeSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CsiNodeSpecV1Beta1( + obj: CsiNodeSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'drivers': obj.drivers?.map(y => toJson_CsiNodeDriverV1Beta1(y)), + drivers: obj.drivers?.map((y) => toJson_CsiNodeDriverV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23226,22 +25756,28 @@ export interface VolumeAttachmentSpecV1Beta1 { * @schema io.k8s.api.storage.v1beta1.VolumeAttachmentSpec#source */ readonly source: VolumeAttachmentSourceV1Beta1; - } /** * Converts an object of type 'VolumeAttachmentSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeAttachmentSpecV1Beta1(obj: VolumeAttachmentSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeAttachmentSpecV1Beta1( + obj: VolumeAttachmentSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'attacher': obj.attacher, - 'nodeName': obj.nodeName, - 'source': toJson_VolumeAttachmentSourceV1Beta1(obj.source), + attacher: obj.attacher, + nodeName: obj.nodeName, + source: toJson_VolumeAttachmentSourceV1Beta1(obj.source), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23292,25 +25828,33 @@ export interface CustomResourceDefinitionSpec { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceDefinitionSpec#versions */ readonly versions: CustomResourceDefinitionVersion[]; - } /** * Converts an object of type 'CustomResourceDefinitionSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceDefinitionSpec(obj: CustomResourceDefinitionSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceDefinitionSpec( + obj: CustomResourceDefinitionSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'conversion': toJson_CustomResourceConversion(obj.conversion), - 'group': obj.group, - 'names': toJson_CustomResourceDefinitionNames(obj.names), - 'preserveUnknownFields': obj.preserveUnknownFields, - 'scope': obj.scope, - 'versions': obj.versions?.map(y => toJson_CustomResourceDefinitionVersion(y)), + conversion: toJson_CustomResourceConversion(obj.conversion), + group: obj.group, + names: toJson_CustomResourceDefinitionNames(obj.names), + preserveUnknownFields: obj.preserveUnknownFields, + scope: obj.scope, + versions: obj.versions?.map((y) => + toJson_CustomResourceDefinitionVersion(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23391,29 +25935,39 @@ export interface CustomResourceDefinitionSpecV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceDefinitionSpec#versions */ readonly versions?: CustomResourceDefinitionVersionV1Beta1[]; - } /** * Converts an object of type 'CustomResourceDefinitionSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceDefinitionSpecV1Beta1(obj: CustomResourceDefinitionSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceDefinitionSpecV1Beta1( + obj: CustomResourceDefinitionSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'additionalPrinterColumns': obj.additionalPrinterColumns?.map(y => toJson_CustomResourceColumnDefinitionV1Beta1(y)), - 'conversion': toJson_CustomResourceConversionV1Beta1(obj.conversion), - 'group': obj.group, - 'names': toJson_CustomResourceDefinitionNamesV1Beta1(obj.names), - 'preserveUnknownFields': obj.preserveUnknownFields, - 'scope': obj.scope, - 'subresources': toJson_CustomResourceSubresourcesV1Beta1(obj.subresources), - 'validation': toJson_CustomResourceValidationV1Beta1(obj.validation), - 'version': obj.version, - 'versions': obj.versions?.map(y => toJson_CustomResourceDefinitionVersionV1Beta1(y)), + additionalPrinterColumns: obj.additionalPrinterColumns?.map((y) => + toJson_CustomResourceColumnDefinitionV1Beta1(y) + ), + conversion: toJson_CustomResourceConversionV1Beta1(obj.conversion), + group: obj.group, + names: toJson_CustomResourceDefinitionNamesV1Beta1(obj.names), + preserveUnknownFields: obj.preserveUnknownFields, + scope: obj.scope, + subresources: toJson_CustomResourceSubresourcesV1Beta1(obj.subresources), + validation: toJson_CustomResourceValidationV1Beta1(obj.validation), + version: obj.version, + versions: obj.versions?.map((y) => + toJson_CustomResourceDefinitionVersionV1Beta1(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23464,25 +26018,31 @@ export interface StatusDetails { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.StatusDetails#uid */ readonly uid?: string; - } /** * Converts an object of type 'StatusDetails' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_StatusDetails(obj: StatusDetails | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_StatusDetails( + obj: StatusDetails | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'causes': obj.causes?.map(y => toJson_StatusCause(y)), - 'group': obj.group, - 'kind': obj.kind, - 'name': obj.name, - 'retryAfterSeconds': obj.retryAfterSeconds, - 'uid': obj.uid, + causes: obj.causes?.map((y) => toJson_StatusCause(y)), + group: obj.group, + kind: obj.kind, + name: obj.name, + retryAfterSeconds: obj.retryAfterSeconds, + uid: obj.uid, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23540,26 +26100,32 @@ export interface ApiServiceSpec { * @schema io.k8s.kube-aggregator.pkg.apis.apiregistration.v1.APIServiceSpec#versionPriority */ readonly versionPriority: number; - } /** * Converts an object of type 'ApiServiceSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ApiServiceSpec(obj: ApiServiceSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ApiServiceSpec( + obj: ApiServiceSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'caBundle': obj.caBundle, - 'group': obj.group, - 'groupPriorityMinimum': obj.groupPriorityMinimum, - 'insecureSkipTLSVerify': obj.insecureSkipTlsVerify, - 'service': toJson_ServiceReference(obj.service), - 'version': obj.version, - 'versionPriority': obj.versionPriority, + caBundle: obj.caBundle, + group: obj.group, + groupPriorityMinimum: obj.groupPriorityMinimum, + insecureSkipTLSVerify: obj.insecureSkipTlsVerify, + service: toJson_ServiceReference(obj.service), + version: obj.version, + versionPriority: obj.versionPriority, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23617,26 +26183,32 @@ export interface ApiServiceSpecV1Beta1 { * @schema io.k8s.kube-aggregator.pkg.apis.apiregistration.v1beta1.APIServiceSpec#versionPriority */ readonly versionPriority: number; - } /** * Converts an object of type 'ApiServiceSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ApiServiceSpecV1Beta1(obj: ApiServiceSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ApiServiceSpecV1Beta1( + obj: ApiServiceSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'caBundle': obj.caBundle, - 'group': obj.group, - 'groupPriorityMinimum': obj.groupPriorityMinimum, - 'insecureSkipTLSVerify': obj.insecureSkipTlsVerify, - 'service': toJson_ServiceReferenceV1Beta1(obj.service), - 'version': obj.version, - 'versionPriority': obj.versionPriority, + caBundle: obj.caBundle, + group: obj.group, + groupPriorityMinimum: obj.groupPriorityMinimum, + insecureSkipTLSVerify: obj.insecureSkipTlsVerify, + service: toJson_ServiceReferenceV1Beta1(obj.service), + version: obj.version, + versionPriority: obj.versionPriority, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23687,25 +26259,31 @@ export interface ManagedFieldsEntry { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.ManagedFieldsEntry#time */ readonly time?: Date; - } /** * Converts an object of type 'ManagedFieldsEntry' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ManagedFieldsEntry(obj: ManagedFieldsEntry | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ManagedFieldsEntry( + obj: ManagedFieldsEntry | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'fieldsType': obj.fieldsType, - 'fieldsV1': obj.fieldsV1, - 'manager': obj.manager, - 'operation': obj.operation, - 'time': obj.time?.toISOString(), + apiVersion: obj.apiVersion, + fieldsType: obj.fieldsType, + fieldsV1: obj.fieldsV1, + manager: obj.manager, + operation: obj.operation, + time: obj.time?.toISOString(), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23757,25 +26335,31 @@ export interface OwnerReference { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.OwnerReference#uid */ readonly uid: string; - } /** * Converts an object of type 'OwnerReference' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_OwnerReference(obj: OwnerReference | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_OwnerReference( + obj: OwnerReference | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'blockOwnerDeletion': obj.blockOwnerDeletion, - 'controller': obj.controller, - 'kind': obj.kind, - 'name': obj.name, - 'uid': obj.uid, + apiVersion: obj.apiVersion, + blockOwnerDeletion: obj.blockOwnerDeletion, + controller: obj.controller, + kind: obj.kind, + name: obj.name, + uid: obj.uid, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23817,22 +26401,28 @@ export interface WebhookClientConfig { * @schema io.k8s.api.admissionregistration.v1.WebhookClientConfig#url */ readonly url?: string; - } /** * Converts an object of type 'WebhookClientConfig' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_WebhookClientConfig(obj: WebhookClientConfig | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_WebhookClientConfig( + obj: WebhookClientConfig | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'caBundle': obj.caBundle, - 'service': toJson_ServiceReference(obj.service), - 'url': obj.url, + caBundle: obj.caBundle, + service: toJson_ServiceReference(obj.service), + url: obj.url, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23883,24 +26473,30 @@ export interface RuleWithOperations { * @schema io.k8s.api.admissionregistration.v1.RuleWithOperations#scope */ readonly scope?: string; - } /** * Converts an object of type 'RuleWithOperations' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RuleWithOperations(obj: RuleWithOperations | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RuleWithOperations( + obj: RuleWithOperations | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroups': obj.apiGroups?.map(y => y), - 'apiVersions': obj.apiVersions?.map(y => y), - 'operations': obj.operations?.map(y => y), - 'resources': obj.resources?.map(y => y), - 'scope': obj.scope, + apiGroups: obj.apiGroups?.map((y) => y), + apiVersions: obj.apiVersions?.map((y) => y), + operations: obj.operations?.map((y) => y), + resources: obj.resources?.map((y) => y), + scope: obj.scope, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -23942,22 +26538,28 @@ export interface WebhookClientConfigV1Beta1 { * @schema io.k8s.api.admissionregistration.v1beta1.WebhookClientConfig#url */ readonly url?: string; - } /** * Converts an object of type 'WebhookClientConfigV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_WebhookClientConfigV1Beta1(obj: WebhookClientConfigV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_WebhookClientConfigV1Beta1( + obj: WebhookClientConfigV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'caBundle': obj.caBundle, - 'service': toJson_ServiceReferenceV1Beta1(obj.service), - 'url': obj.url, + caBundle: obj.caBundle, + service: toJson_ServiceReferenceV1Beta1(obj.service), + url: obj.url, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24008,24 +26610,30 @@ export interface RuleWithOperationsV1Beta1 { * @schema io.k8s.api.admissionregistration.v1beta1.RuleWithOperations#scope */ readonly scope?: string; - } /** * Converts an object of type 'RuleWithOperationsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RuleWithOperationsV1Beta1(obj: RuleWithOperationsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RuleWithOperationsV1Beta1( + obj: RuleWithOperationsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroups': obj.apiGroups?.map(y => y), - 'apiVersions': obj.apiVersions?.map(y => y), - 'operations': obj.operations?.map(y => y), - 'resources': obj.resources?.map(y => y), - 'scope': obj.scope, + apiGroups: obj.apiGroups?.map((y) => y), + apiVersions: obj.apiVersions?.map((y) => y), + operations: obj.operations?.map((y) => y), + resources: obj.resources?.map((y) => y), + scope: obj.scope, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24049,21 +26657,27 @@ export interface DaemonSetUpdateStrategy { * @schema io.k8s.api.apps.v1.DaemonSetUpdateStrategy#type */ readonly type?: string; - } /** * Converts an object of type 'DaemonSetUpdateStrategy' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_DaemonSetUpdateStrategy(obj: DaemonSetUpdateStrategy | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_DaemonSetUpdateStrategy( + obj: DaemonSetUpdateStrategy | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'rollingUpdate': toJson_RollingUpdateDaemonSet(obj.rollingUpdate), - 'type': obj.type, + rollingUpdate: toJson_RollingUpdateDaemonSet(obj.rollingUpdate), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24087,21 +26701,27 @@ export interface DeploymentStrategy { * @schema io.k8s.api.apps.v1.DeploymentStrategy#type */ readonly type?: string; - } /** * Converts an object of type 'DeploymentStrategy' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_DeploymentStrategy(obj: DeploymentStrategy | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_DeploymentStrategy( + obj: DeploymentStrategy | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'rollingUpdate': toJson_RollingUpdateDeployment(obj.rollingUpdate), - 'type': obj.type, + rollingUpdate: toJson_RollingUpdateDeployment(obj.rollingUpdate), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24125,21 +26745,27 @@ export interface StatefulSetUpdateStrategy { * @schema io.k8s.api.apps.v1.StatefulSetUpdateStrategy#type */ readonly type?: string; - } /** * Converts an object of type 'StatefulSetUpdateStrategy' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_StatefulSetUpdateStrategy(obj: StatefulSetUpdateStrategy | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_StatefulSetUpdateStrategy( + obj: StatefulSetUpdateStrategy | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'rollingUpdate': toJson_RollingUpdateStatefulSetStrategy(obj.rollingUpdate), - 'type': obj.type, + rollingUpdate: toJson_RollingUpdateStatefulSetStrategy(obj.rollingUpdate), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24176,23 +26802,29 @@ export interface BoundObjectReference { * @schema io.k8s.api.authentication.v1.BoundObjectReference#uid */ readonly uid?: string; - } /** * Converts an object of type 'BoundObjectReference' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_BoundObjectReference(obj: BoundObjectReference | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_BoundObjectReference( + obj: BoundObjectReference | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'kind': obj.kind, - 'name': obj.name, - 'uid': obj.uid, + apiVersion: obj.apiVersion, + kind: obj.kind, + name: obj.name, + uid: obj.uid, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24215,21 +26847,27 @@ export interface NonResourceAttributes { * @schema io.k8s.api.authorization.v1.NonResourceAttributes#verb */ readonly verb?: string; - } /** * Converts an object of type 'NonResourceAttributes' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NonResourceAttributes(obj: NonResourceAttributes | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NonResourceAttributes( + obj: NonResourceAttributes | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'path': obj.path, - 'verb': obj.verb, + path: obj.path, + verb: obj.verb, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24287,26 +26925,32 @@ export interface ResourceAttributes { * @schema io.k8s.api.authorization.v1.ResourceAttributes#version */ readonly version?: string; - } /** * Converts an object of type 'ResourceAttributes' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ResourceAttributes(obj: ResourceAttributes | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ResourceAttributes( + obj: ResourceAttributes | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'group': obj.group, - 'name': obj.name, - 'namespace': obj.namespace, - 'resource': obj.resource, - 'subresource': obj.subresource, - 'verb': obj.verb, - 'version': obj.version, + group: obj.group, + name: obj.name, + namespace: obj.namespace, + resource: obj.resource, + subresource: obj.subresource, + verb: obj.verb, + version: obj.version, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24329,21 +26973,27 @@ export interface NonResourceAttributesV1Beta1 { * @schema io.k8s.api.authorization.v1beta1.NonResourceAttributes#verb */ readonly verb?: string; - } /** * Converts an object of type 'NonResourceAttributesV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NonResourceAttributesV1Beta1(obj: NonResourceAttributesV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NonResourceAttributesV1Beta1( + obj: NonResourceAttributesV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'path': obj.path, - 'verb': obj.verb, + path: obj.path, + verb: obj.verb, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24401,26 +27051,32 @@ export interface ResourceAttributesV1Beta1 { * @schema io.k8s.api.authorization.v1beta1.ResourceAttributes#version */ readonly version?: string; - } /** * Converts an object of type 'ResourceAttributesV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ResourceAttributesV1Beta1(obj: ResourceAttributesV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ResourceAttributesV1Beta1( + obj: ResourceAttributesV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'group': obj.group, - 'name': obj.name, - 'namespace': obj.namespace, - 'resource': obj.resource, - 'subresource': obj.subresource, - 'verb': obj.verb, - 'version': obj.version, + group: obj.group, + name: obj.name, + namespace: obj.namespace, + resource: obj.resource, + subresource: obj.subresource, + verb: obj.verb, + version: obj.version, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24450,22 +27106,28 @@ export interface CrossVersionObjectReference { * @schema io.k8s.api.autoscaling.v1.CrossVersionObjectReference#name */ readonly name: string; - } /** * Converts an object of type 'CrossVersionObjectReference' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CrossVersionObjectReference(obj: CrossVersionObjectReference | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CrossVersionObjectReference( + obj: CrossVersionObjectReference | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'kind': obj.kind, - 'name': obj.name, + apiVersion: obj.apiVersion, + kind: obj.kind, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24516,25 +27178,33 @@ export interface MetricSpecV2Beta1 { * @schema io.k8s.api.autoscaling.v2beta1.MetricSpec#type */ readonly type: string; - } /** * Converts an object of type 'MetricSpecV2Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_MetricSpecV2Beta1(obj: MetricSpecV2Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_MetricSpecV2Beta1( + obj: MetricSpecV2Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'containerResource': toJson_ContainerResourceMetricSourceV2Beta1(obj.containerResource), - 'external': toJson_ExternalMetricSourceV2Beta1(obj.external), - 'object': toJson_ObjectMetricSourceV2Beta1(obj.object), - 'pods': toJson_PodsMetricSourceV2Beta1(obj.pods), - 'resource': toJson_ResourceMetricSourceV2Beta1(obj.resource), - 'type': obj.type, + containerResource: toJson_ContainerResourceMetricSourceV2Beta1( + obj.containerResource + ), + external: toJson_ExternalMetricSourceV2Beta1(obj.external), + object: toJson_ObjectMetricSourceV2Beta1(obj.object), + pods: toJson_PodsMetricSourceV2Beta1(obj.pods), + resource: toJson_ResourceMetricSourceV2Beta1(obj.resource), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24564,22 +27234,28 @@ export interface CrossVersionObjectReferenceV2Beta1 { * @schema io.k8s.api.autoscaling.v2beta1.CrossVersionObjectReference#name */ readonly name: string; - } /** * Converts an object of type 'CrossVersionObjectReferenceV2Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CrossVersionObjectReferenceV2Beta1(obj: CrossVersionObjectReferenceV2Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CrossVersionObjectReferenceV2Beta1( + obj: CrossVersionObjectReferenceV2Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'kind': obj.kind, - 'name': obj.name, + apiVersion: obj.apiVersion, + kind: obj.kind, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24605,21 +27281,27 @@ export interface HorizontalPodAutoscalerBehaviorV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.HorizontalPodAutoscalerBehavior#scaleUp */ readonly scaleUp?: HpaScalingRulesV2Beta2; - } /** * Converts an object of type 'HorizontalPodAutoscalerBehaviorV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HorizontalPodAutoscalerBehaviorV2Beta2(obj: HorizontalPodAutoscalerBehaviorV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HorizontalPodAutoscalerBehaviorV2Beta2( + obj: HorizontalPodAutoscalerBehaviorV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'scaleDown': toJson_HpaScalingRulesV2Beta2(obj.scaleDown), - 'scaleUp': toJson_HpaScalingRulesV2Beta2(obj.scaleUp), + scaleDown: toJson_HpaScalingRulesV2Beta2(obj.scaleDown), + scaleUp: toJson_HpaScalingRulesV2Beta2(obj.scaleUp), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24670,25 +27352,33 @@ export interface MetricSpecV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.MetricSpec#type */ readonly type: string; - } /** * Converts an object of type 'MetricSpecV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_MetricSpecV2Beta2(obj: MetricSpecV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_MetricSpecV2Beta2( + obj: MetricSpecV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'containerResource': toJson_ContainerResourceMetricSourceV2Beta2(obj.containerResource), - 'external': toJson_ExternalMetricSourceV2Beta2(obj.external), - 'object': toJson_ObjectMetricSourceV2Beta2(obj.object), - 'pods': toJson_PodsMetricSourceV2Beta2(obj.pods), - 'resource': toJson_ResourceMetricSourceV2Beta2(obj.resource), - 'type': obj.type, + containerResource: toJson_ContainerResourceMetricSourceV2Beta2( + obj.containerResource + ), + external: toJson_ExternalMetricSourceV2Beta2(obj.external), + object: toJson_ObjectMetricSourceV2Beta2(obj.object), + pods: toJson_PodsMetricSourceV2Beta2(obj.pods), + resource: toJson_ResourceMetricSourceV2Beta2(obj.resource), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24718,22 +27408,28 @@ export interface CrossVersionObjectReferenceV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.CrossVersionObjectReference#name */ readonly name: string; - } /** * Converts an object of type 'CrossVersionObjectReferenceV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CrossVersionObjectReferenceV2Beta2(obj: CrossVersionObjectReferenceV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CrossVersionObjectReferenceV2Beta2( + obj: CrossVersionObjectReferenceV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'kind': obj.kind, - 'name': obj.name, + apiVersion: obj.apiVersion, + kind: obj.kind, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24756,21 +27452,27 @@ export interface JobTemplateSpec { * @schema io.k8s.api.batch.v1.JobTemplateSpec#spec */ readonly spec?: JobSpec; - } /** * Converts an object of type 'JobTemplateSpec' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_JobTemplateSpec(obj: JobTemplateSpec | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_JobTemplateSpec( + obj: JobTemplateSpec | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_JobSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_JobSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24793,21 +27495,27 @@ export interface JobTemplateSpecV1Beta1 { * @schema io.k8s.api.batch.v1beta1.JobTemplateSpec#spec */ readonly spec?: JobSpec; - } /** * Converts an object of type 'JobTemplateSpecV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_JobTemplateSpecV1Beta1(obj: JobTemplateSpecV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_JobTemplateSpecV1Beta1( + obj: JobTemplateSpecV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_JobSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_JobSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24844,23 +27552,29 @@ export interface EndpointAddress { * @schema io.k8s.api.core.v1.EndpointAddress#targetRef */ readonly targetRef?: ObjectReference; - } /** * Converts an object of type 'EndpointAddress' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EndpointAddress(obj: EndpointAddress | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EndpointAddress( + obj: EndpointAddress | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'hostname': obj.hostname, - 'ip': obj.ip, - 'nodeName': obj.nodeName, - 'targetRef': toJson_ObjectReference(obj.targetRef), + hostname: obj.hostname, + ip: obj.ip, + nodeName: obj.nodeName, + targetRef: toJson_ObjectReference(obj.targetRef), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24891,22 +27605,28 @@ export interface EnvVar { * @schema io.k8s.api.core.v1.EnvVar#valueFrom */ readonly valueFrom?: EnvVarSource; - } /** * Converts an object of type 'EnvVar' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EnvVar(obj: EnvVar | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EnvVar( + obj: EnvVar | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'value': obj.value, - 'valueFrom': toJson_EnvVarSource(obj.valueFrom), + name: obj.name, + value: obj.value, + valueFrom: toJson_EnvVarSource(obj.valueFrom), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24936,22 +27656,28 @@ export interface EnvFromSource { * @schema io.k8s.api.core.v1.EnvFromSource#secretRef */ readonly secretRef?: SecretEnvSource; - } /** * Converts an object of type 'EnvFromSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EnvFromSource(obj: EnvFromSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EnvFromSource( + obj: EnvFromSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'configMapRef': toJson_ConfigMapEnvSource(obj.configMapRef), - 'prefix': obj.prefix, - 'secretRef': toJson_SecretEnvSource(obj.secretRef), + configMapRef: toJson_ConfigMapEnvSource(obj.configMapRef), + prefix: obj.prefix, + secretRef: toJson_SecretEnvSource(obj.secretRef), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -24974,21 +27700,27 @@ export interface Lifecycle { * @schema io.k8s.api.core.v1.Lifecycle#preStop */ readonly preStop?: Handler; - } /** * Converts an object of type 'Lifecycle' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Lifecycle(obj: Lifecycle | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Lifecycle( + obj: Lifecycle | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'postStart': toJson_Handler(obj.postStart), - 'preStop': toJson_Handler(obj.preStop), + postStart: toJson_Handler(obj.postStart), + preStop: toJson_Handler(obj.preStop), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25064,28 +27796,34 @@ export interface Probe { * @schema io.k8s.api.core.v1.Probe#timeoutSeconds */ readonly timeoutSeconds?: number; - } /** * Converts an object of type 'Probe' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Probe(obj: Probe | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Probe( + obj: Probe | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'exec': toJson_ExecAction(obj.exec), - 'failureThreshold': obj.failureThreshold, - 'httpGet': toJson_HttpGetAction(obj.httpGet), - 'initialDelaySeconds': obj.initialDelaySeconds, - 'periodSeconds': obj.periodSeconds, - 'successThreshold': obj.successThreshold, - 'tcpSocket': toJson_TcpSocketAction(obj.tcpSocket), - 'terminationGracePeriodSeconds': obj.terminationGracePeriodSeconds, - 'timeoutSeconds': obj.timeoutSeconds, + exec: toJson_ExecAction(obj.exec), + failureThreshold: obj.failureThreshold, + httpGet: toJson_HttpGetAction(obj.httpGet), + initialDelaySeconds: obj.initialDelaySeconds, + periodSeconds: obj.periodSeconds, + successThreshold: obj.successThreshold, + tcpSocket: toJson_TcpSocketAction(obj.tcpSocket), + terminationGracePeriodSeconds: obj.terminationGracePeriodSeconds, + timeoutSeconds: obj.timeoutSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25130,24 +27868,30 @@ export interface ContainerPort { * @schema io.k8s.api.core.v1.ContainerPort#protocol */ readonly protocol?: string; - } /** * Converts an object of type 'ContainerPort' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ContainerPort(obj: ContainerPort | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ContainerPort( + obj: ContainerPort | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'containerPort': obj.containerPort, - 'hostIP': obj.hostIp, - 'hostPort': obj.hostPort, - 'name': obj.name, - 'protocol': obj.protocol, + containerPort: obj.containerPort, + hostIP: obj.hostIp, + hostPort: obj.hostPort, + name: obj.name, + protocol: obj.protocol, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25170,21 +27914,39 @@ export interface ResourceRequirements { * @schema io.k8s.api.core.v1.ResourceRequirements#requests */ readonly requests?: { [key: string]: Quantity }; - } /** * Converts an object of type 'ResourceRequirements' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ResourceRequirements(obj: ResourceRequirements | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ResourceRequirements( + obj: ResourceRequirements | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'limits': ((obj.limits) === undefined) ? undefined : (Object.entries(obj.limits).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), - 'requests': ((obj.requests) === undefined) ? undefined : (Object.entries(obj.requests).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), + limits: + obj.limits === undefined + ? undefined + : Object.entries(obj.limits).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), + requests: + obj.requests === undefined + ? undefined + : Object.entries(obj.requests).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25274,30 +28036,36 @@ export interface SecurityContext { * @schema io.k8s.api.core.v1.SecurityContext#windowsOptions */ readonly windowsOptions?: WindowsSecurityContextOptions; - } /** * Converts an object of type 'SecurityContext' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SecurityContext(obj: SecurityContext | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SecurityContext( + obj: SecurityContext | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'allowPrivilegeEscalation': obj.allowPrivilegeEscalation, - 'capabilities': toJson_Capabilities(obj.capabilities), - 'privileged': obj.privileged, - 'procMount': obj.procMount, - 'readOnlyRootFilesystem': obj.readOnlyRootFilesystem, - 'runAsGroup': obj.runAsGroup, - 'runAsNonRoot': obj.runAsNonRoot, - 'runAsUser': obj.runAsUser, - 'seLinuxOptions': toJson_SeLinuxOptions(obj.seLinuxOptions), - 'seccompProfile': toJson_SeccompProfile(obj.seccompProfile), - 'windowsOptions': toJson_WindowsSecurityContextOptions(obj.windowsOptions), + allowPrivilegeEscalation: obj.allowPrivilegeEscalation, + capabilities: toJson_Capabilities(obj.capabilities), + privileged: obj.privileged, + procMount: obj.procMount, + readOnlyRootFilesystem: obj.readOnlyRootFilesystem, + runAsGroup: obj.runAsGroup, + runAsNonRoot: obj.runAsNonRoot, + runAsUser: obj.runAsUser, + seLinuxOptions: toJson_SeLinuxOptions(obj.seLinuxOptions), + seccompProfile: toJson_SeccompProfile(obj.seccompProfile), + windowsOptions: toJson_WindowsSecurityContextOptions(obj.windowsOptions), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25320,21 +28088,27 @@ export interface VolumeDevice { * @schema io.k8s.api.core.v1.VolumeDevice#name */ readonly name: string; - } /** * Converts an object of type 'VolumeDevice' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeDevice(obj: VolumeDevice | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeDevice( + obj: VolumeDevice | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'devicePath': obj.devicePath, - 'name': obj.name, + devicePath: obj.devicePath, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25388,25 +28162,31 @@ export interface VolumeMount { * @schema io.k8s.api.core.v1.VolumeMount#subPathExpr */ readonly subPathExpr?: string; - } /** * Converts an object of type 'VolumeMount' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeMount(obj: VolumeMount | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeMount( + obj: VolumeMount | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'mountPath': obj.mountPath, - 'mountPropagation': obj.mountPropagation, - 'name': obj.name, - 'readOnly': obj.readOnly, - 'subPath': obj.subPath, - 'subPathExpr': obj.subPathExpr, + mountPath: obj.mountPath, + mountPropagation: obj.mountPropagation, + name: obj.name, + readOnly: obj.readOnly, + subPath: obj.subPath, + subPathExpr: obj.subPathExpr, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25457,25 +28237,61 @@ export interface LimitRangeItem { * @schema io.k8s.api.core.v1.LimitRangeItem#type */ readonly type: string; - } /** * Converts an object of type 'LimitRangeItem' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LimitRangeItem(obj: LimitRangeItem | undefined): Record | undefined { - if (obj === undefined) { return undefined; } - const result = { - 'default': ((obj.default) === undefined) ? undefined : (Object.entries(obj.default).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), - 'defaultRequest': ((obj.defaultRequest) === undefined) ? undefined : (Object.entries(obj.defaultRequest).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), - 'max': ((obj.max) === undefined) ? undefined : (Object.entries(obj.max).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), - 'maxLimitRequestRatio': ((obj.maxLimitRequestRatio) === undefined) ? undefined : (Object.entries(obj.maxLimitRequestRatio).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), - 'min': ((obj.min) === undefined) ? undefined : (Object.entries(obj.min).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), - 'type': obj.type, - }; - // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); +export function toJson_LimitRangeItem( + obj: LimitRangeItem | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } + const result = { + default: + obj.default === undefined + ? undefined + : Object.entries(obj.default).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), + defaultRequest: + obj.defaultRequest === undefined + ? undefined + : Object.entries(obj.defaultRequest).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), + max: + obj.max === undefined + ? undefined + : Object.entries(obj.max).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), + maxLimitRequestRatio: + obj.maxLimitRequestRatio === undefined + ? undefined + : Object.entries(obj.maxLimitRequestRatio).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), + min: + obj.min === undefined + ? undefined + : Object.entries(obj.min).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), + type: obj.type, + }; + // filter undefined values + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25491,20 +28307,26 @@ export interface NodeConfigSource { * @schema io.k8s.api.core.v1.NodeConfigSource#configMap */ readonly configMap?: ConfigMapNodeConfigSource; - } /** * Converts an object of type 'NodeConfigSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NodeConfigSource(obj: NodeConfigSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NodeConfigSource( + obj: NodeConfigSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'configMap': toJson_ConfigMapNodeConfigSource(obj.configMap), + configMap: toJson_ConfigMapNodeConfigSource(obj.configMap), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25541,23 +28363,29 @@ export interface Taint { * @schema io.k8s.api.core.v1.Taint#value */ readonly value?: string; - } /** * Converts an object of type 'Taint' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Taint(obj: Taint | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Taint( + obj: Taint | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'effect': obj.effect, - 'key': obj.key, - 'timeAdded': obj.timeAdded?.toISOString(), - 'value': obj.value, + effect: obj.effect, + key: obj.key, + timeAdded: obj.timeAdded?.toISOString(), + value: obj.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25596,23 +28424,29 @@ export interface AwsElasticBlockStoreVolumeSource { * @schema io.k8s.api.core.v1.AWSElasticBlockStoreVolumeSource#volumeID */ readonly volumeId: string; - } /** * Converts an object of type 'AwsElasticBlockStoreVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AwsElasticBlockStoreVolumeSource(obj: AwsElasticBlockStoreVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AwsElasticBlockStoreVolumeSource( + obj: AwsElasticBlockStoreVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'partition': obj.partition, - 'readOnly': obj.readOnly, - 'volumeID': obj.volumeId, + fsType: obj.fsType, + partition: obj.partition, + readOnly: obj.readOnly, + volumeID: obj.volumeId, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25664,25 +28498,31 @@ export interface AzureDiskVolumeSource { * @schema io.k8s.api.core.v1.AzureDiskVolumeSource#readOnly */ readonly readOnly?: boolean; - } /** * Converts an object of type 'AzureDiskVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AzureDiskVolumeSource(obj: AzureDiskVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AzureDiskVolumeSource( + obj: AzureDiskVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'cachingMode': obj.cachingMode, - 'diskName': obj.diskName, - 'diskURI': obj.diskUri, - 'fsType': obj.fsType, - 'kind': obj.kind, - 'readOnly': obj.readOnly, + cachingMode: obj.cachingMode, + diskName: obj.diskName, + diskURI: obj.diskUri, + fsType: obj.fsType, + kind: obj.kind, + readOnly: obj.readOnly, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25720,23 +28560,29 @@ export interface AzureFilePersistentVolumeSource { * @schema io.k8s.api.core.v1.AzureFilePersistentVolumeSource#shareName */ readonly shareName: string; - } /** * Converts an object of type 'AzureFilePersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AzureFilePersistentVolumeSource(obj: AzureFilePersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AzureFilePersistentVolumeSource( + obj: AzureFilePersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'readOnly': obj.readOnly, - 'secretName': obj.secretName, - 'secretNamespace': obj.secretNamespace, - 'shareName': obj.shareName, + readOnly: obj.readOnly, + secretName: obj.secretName, + secretNamespace: obj.secretNamespace, + shareName: obj.shareName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25788,25 +28634,31 @@ export interface CephFsPersistentVolumeSource { * @schema io.k8s.api.core.v1.CephFSPersistentVolumeSource#user */ readonly user?: string; - } /** * Converts an object of type 'CephFsPersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CephFsPersistentVolumeSource(obj: CephFsPersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CephFsPersistentVolumeSource( + obj: CephFsPersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'monitors': obj.monitors?.map(y => y), - 'path': obj.path, - 'readOnly': obj.readOnly, - 'secretFile': obj.secretFile, - 'secretRef': toJson_SecretReference(obj.secretRef), - 'user': obj.user, + monitors: obj.monitors?.map((y) => y), + path: obj.path, + readOnly: obj.readOnly, + secretFile: obj.secretFile, + secretRef: toJson_SecretReference(obj.secretRef), + user: obj.user, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25844,23 +28696,29 @@ export interface CinderPersistentVolumeSource { * @schema io.k8s.api.core.v1.CinderPersistentVolumeSource#volumeID */ readonly volumeId: string; - } /** * Converts an object of type 'CinderPersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CinderPersistentVolumeSource(obj: CinderPersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CinderPersistentVolumeSource( + obj: CinderPersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'readOnly': obj.readOnly, - 'secretRef': toJson_SecretReference(obj.secretRef), - 'volumeID': obj.volumeId, + fsType: obj.fsType, + readOnly: obj.readOnly, + secretRef: toJson_SecretReference(obj.secretRef), + volumeID: obj.volumeId, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25933,28 +28791,44 @@ export interface CsiPersistentVolumeSource { * @schema io.k8s.api.core.v1.CSIPersistentVolumeSource#volumeHandle */ readonly volumeHandle: string; - } /** * Converts an object of type 'CsiPersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CsiPersistentVolumeSource(obj: CsiPersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CsiPersistentVolumeSource( + obj: CsiPersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'controllerExpandSecretRef': toJson_SecretReference(obj.controllerExpandSecretRef), - 'controllerPublishSecretRef': toJson_SecretReference(obj.controllerPublishSecretRef), - 'driver': obj.driver, - 'fsType': obj.fsType, - 'nodePublishSecretRef': toJson_SecretReference(obj.nodePublishSecretRef), - 'nodeStageSecretRef': toJson_SecretReference(obj.nodeStageSecretRef), - 'readOnly': obj.readOnly, - 'volumeAttributes': ((obj.volumeAttributes) === undefined) ? undefined : (Object.entries(obj.volumeAttributes).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'volumeHandle': obj.volumeHandle, + controllerExpandSecretRef: toJson_SecretReference( + obj.controllerExpandSecretRef + ), + controllerPublishSecretRef: toJson_SecretReference( + obj.controllerPublishSecretRef + ), + driver: obj.driver, + fsType: obj.fsType, + nodePublishSecretRef: toJson_SecretReference(obj.nodePublishSecretRef), + nodeStageSecretRef: toJson_SecretReference(obj.nodeStageSecretRef), + readOnly: obj.readOnly, + volumeAttributes: + obj.volumeAttributes === undefined + ? undefined + : Object.entries(obj.volumeAttributes).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + volumeHandle: obj.volumeHandle, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -25999,24 +28873,30 @@ export interface FcVolumeSource { * @schema io.k8s.api.core.v1.FCVolumeSource#wwids */ readonly wwids?: string[]; - } /** * Converts an object of type 'FcVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_FcVolumeSource(obj: FcVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_FcVolumeSource( + obj: FcVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'lun': obj.lun, - 'readOnly': obj.readOnly, - 'targetWWNs': obj.targetWwNs?.map(y => y), - 'wwids': obj.wwids?.map(y => y), + fsType: obj.fsType, + lun: obj.lun, + readOnly: obj.readOnly, + targetWWNs: obj.targetWwNs?.map((y) => y), + wwids: obj.wwids?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26061,24 +28941,36 @@ export interface FlexPersistentVolumeSource { * @schema io.k8s.api.core.v1.FlexPersistentVolumeSource#secretRef */ readonly secretRef?: SecretReference; - } /** * Converts an object of type 'FlexPersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_FlexPersistentVolumeSource(obj: FlexPersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_FlexPersistentVolumeSource( + obj: FlexPersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'driver': obj.driver, - 'fsType': obj.fsType, - 'options': ((obj.options) === undefined) ? undefined : (Object.entries(obj.options).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'readOnly': obj.readOnly, - 'secretRef': toJson_SecretReference(obj.secretRef), + driver: obj.driver, + fsType: obj.fsType, + options: + obj.options === undefined + ? undefined + : Object.entries(obj.options).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + readOnly: obj.readOnly, + secretRef: toJson_SecretReference(obj.secretRef), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26101,21 +28993,27 @@ export interface FlockerVolumeSource { * @schema io.k8s.api.core.v1.FlockerVolumeSource#datasetUUID */ readonly datasetUuid?: string; - } /** * Converts an object of type 'FlockerVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_FlockerVolumeSource(obj: FlockerVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_FlockerVolumeSource( + obj: FlockerVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'datasetName': obj.datasetName, - 'datasetUUID': obj.datasetUuid, + datasetName: obj.datasetName, + datasetUUID: obj.datasetUuid, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26155,23 +29053,29 @@ export interface GcePersistentDiskVolumeSource { * @schema io.k8s.api.core.v1.GCEPersistentDiskVolumeSource#readOnly */ readonly readOnly?: boolean; - } /** * Converts an object of type 'GcePersistentDiskVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_GcePersistentDiskVolumeSource(obj: GcePersistentDiskVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_GcePersistentDiskVolumeSource( + obj: GcePersistentDiskVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'partition': obj.partition, - 'pdName': obj.pdName, - 'readOnly': obj.readOnly, + fsType: obj.fsType, + partition: obj.partition, + pdName: obj.pdName, + readOnly: obj.readOnly, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26209,23 +29113,29 @@ export interface GlusterfsPersistentVolumeSource { * @schema io.k8s.api.core.v1.GlusterfsPersistentVolumeSource#readOnly */ readonly readOnly?: boolean; - } /** * Converts an object of type 'GlusterfsPersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_GlusterfsPersistentVolumeSource(obj: GlusterfsPersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_GlusterfsPersistentVolumeSource( + obj: GlusterfsPersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'endpoints': obj.endpoints, - 'endpointsNamespace': obj.endpointsNamespace, - 'path': obj.path, - 'readOnly': obj.readOnly, + endpoints: obj.endpoints, + endpointsNamespace: obj.endpointsNamespace, + path: obj.path, + readOnly: obj.readOnly, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26249,21 +29159,27 @@ export interface HostPathVolumeSource { * @schema io.k8s.api.core.v1.HostPathVolumeSource#type */ readonly type?: string; - } /** * Converts an object of type 'HostPathVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HostPathVolumeSource(obj: HostPathVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HostPathVolumeSource( + obj: HostPathVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'path': obj.path, - 'type': obj.type, + path: obj.path, + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26351,30 +29267,36 @@ export interface IscsiPersistentVolumeSource { * @schema io.k8s.api.core.v1.ISCSIPersistentVolumeSource#targetPortal */ readonly targetPortal: string; - } /** * Converts an object of type 'IscsiPersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IscsiPersistentVolumeSource(obj: IscsiPersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IscsiPersistentVolumeSource( + obj: IscsiPersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'chapAuthDiscovery': obj.chapAuthDiscovery, - 'chapAuthSession': obj.chapAuthSession, - 'fsType': obj.fsType, - 'initiatorName': obj.initiatorName, - 'iqn': obj.iqn, - 'iscsiInterface': obj.iscsiInterface, - 'lun': obj.lun, - 'portals': obj.portals?.map(y => y), - 'readOnly': obj.readOnly, - 'secretRef': toJson_SecretReference(obj.secretRef), - 'targetPortal': obj.targetPortal, + chapAuthDiscovery: obj.chapAuthDiscovery, + chapAuthSession: obj.chapAuthSession, + fsType: obj.fsType, + initiatorName: obj.initiatorName, + iqn: obj.iqn, + iscsiInterface: obj.iscsiInterface, + lun: obj.lun, + portals: obj.portals?.map((y) => y), + readOnly: obj.readOnly, + secretRef: toJson_SecretReference(obj.secretRef), + targetPortal: obj.targetPortal, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26397,21 +29319,27 @@ export interface LocalVolumeSource { * @schema io.k8s.api.core.v1.LocalVolumeSource#path */ readonly path: string; - } /** * Converts an object of type 'LocalVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LocalVolumeSource(obj: LocalVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_LocalVolumeSource( + obj: LocalVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'path': obj.path, + fsType: obj.fsType, + path: obj.path, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26442,22 +29370,28 @@ export interface NfsVolumeSource { * @schema io.k8s.api.core.v1.NFSVolumeSource#server */ readonly server: string; - } /** * Converts an object of type 'NfsVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NfsVolumeSource(obj: NfsVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NfsVolumeSource( + obj: NfsVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'path': obj.path, - 'readOnly': obj.readOnly, - 'server': obj.server, + path: obj.path, + readOnly: obj.readOnly, + server: obj.server, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26473,20 +29407,26 @@ export interface VolumeNodeAffinity { * @schema io.k8s.api.core.v1.VolumeNodeAffinity#required */ readonly required?: NodeSelector; - } /** * Converts an object of type 'VolumeNodeAffinity' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeNodeAffinity(obj: VolumeNodeAffinity | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeNodeAffinity( + obj: VolumeNodeAffinity | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'required': toJson_NodeSelector(obj.required), + required: toJson_NodeSelector(obj.required), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26509,21 +29449,27 @@ export interface PhotonPersistentDiskVolumeSource { * @schema io.k8s.api.core.v1.PhotonPersistentDiskVolumeSource#pdID */ readonly pdId: string; - } /** * Converts an object of type 'PhotonPersistentDiskVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PhotonPersistentDiskVolumeSource(obj: PhotonPersistentDiskVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PhotonPersistentDiskVolumeSource( + obj: PhotonPersistentDiskVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'pdID': obj.pdId, + fsType: obj.fsType, + pdID: obj.pdId, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26554,22 +29500,28 @@ export interface PortworxVolumeSource { * @schema io.k8s.api.core.v1.PortworxVolumeSource#volumeID */ readonly volumeId: string; - } /** * Converts an object of type 'PortworxVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PortworxVolumeSource(obj: PortworxVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PortworxVolumeSource( + obj: PortworxVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'readOnly': obj.readOnly, - 'volumeID': obj.volumeId, + fsType: obj.fsType, + readOnly: obj.readOnly, + volumeID: obj.volumeId, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26623,25 +29575,31 @@ export interface QuobyteVolumeSource { * @schema io.k8s.api.core.v1.QuobyteVolumeSource#volume */ readonly volume: string; - } /** * Converts an object of type 'QuobyteVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_QuobyteVolumeSource(obj: QuobyteVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_QuobyteVolumeSource( + obj: QuobyteVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'group': obj.group, - 'readOnly': obj.readOnly, - 'registry': obj.registry, - 'tenant': obj.tenant, - 'user': obj.user, - 'volume': obj.volume, + group: obj.group, + readOnly: obj.readOnly, + registry: obj.registry, + tenant: obj.tenant, + user: obj.user, + volume: obj.volume, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26711,27 +29669,33 @@ export interface RbdPersistentVolumeSource { * @schema io.k8s.api.core.v1.RBDPersistentVolumeSource#user */ readonly user?: string; - } /** * Converts an object of type 'RbdPersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RbdPersistentVolumeSource(obj: RbdPersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RbdPersistentVolumeSource( + obj: RbdPersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'image': obj.image, - 'keyring': obj.keyring, - 'monitors': obj.monitors?.map(y => y), - 'pool': obj.pool, - 'readOnly': obj.readOnly, - 'secretRef': toJson_SecretReference(obj.secretRef), - 'user': obj.user, + fsType: obj.fsType, + image: obj.image, + keyring: obj.keyring, + monitors: obj.monitors?.map((y) => y), + pool: obj.pool, + readOnly: obj.readOnly, + secretRef: toJson_SecretReference(obj.secretRef), + user: obj.user, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26813,29 +29777,35 @@ export interface ScaleIoPersistentVolumeSource { * @schema io.k8s.api.core.v1.ScaleIOPersistentVolumeSource#volumeName */ readonly volumeName?: string; - } /** * Converts an object of type 'ScaleIoPersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ScaleIoPersistentVolumeSource(obj: ScaleIoPersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ScaleIoPersistentVolumeSource( + obj: ScaleIoPersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'gateway': obj.gateway, - 'protectionDomain': obj.protectionDomain, - 'readOnly': obj.readOnly, - 'secretRef': toJson_SecretReference(obj.secretRef), - 'sslEnabled': obj.sslEnabled, - 'storageMode': obj.storageMode, - 'storagePool': obj.storagePool, - 'system': obj.system, - 'volumeName': obj.volumeName, + fsType: obj.fsType, + gateway: obj.gateway, + protectionDomain: obj.protectionDomain, + readOnly: obj.readOnly, + secretRef: toJson_SecretReference(obj.secretRef), + sslEnabled: obj.sslEnabled, + storageMode: obj.storageMode, + storagePool: obj.storagePool, + system: obj.system, + volumeName: obj.volumeName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26880,24 +29850,30 @@ export interface StorageOsPersistentVolumeSource { * @schema io.k8s.api.core.v1.StorageOSPersistentVolumeSource#volumeNamespace */ readonly volumeNamespace?: string; - } /** * Converts an object of type 'StorageOsPersistentVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_StorageOsPersistentVolumeSource(obj: StorageOsPersistentVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_StorageOsPersistentVolumeSource( + obj: StorageOsPersistentVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'readOnly': obj.readOnly, - 'secretRef': toJson_ObjectReference(obj.secretRef), - 'volumeName': obj.volumeName, - 'volumeNamespace': obj.volumeNamespace, + fsType: obj.fsType, + readOnly: obj.readOnly, + secretRef: toJson_ObjectReference(obj.secretRef), + volumeName: obj.volumeName, + volumeNamespace: obj.volumeNamespace, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26934,23 +29910,29 @@ export interface VsphereVirtualDiskVolumeSource { * @schema io.k8s.api.core.v1.VsphereVirtualDiskVolumeSource#volumePath */ readonly volumePath: string; - } /** * Converts an object of type 'VsphereVirtualDiskVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VsphereVirtualDiskVolumeSource(obj: VsphereVirtualDiskVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VsphereVirtualDiskVolumeSource( + obj: VsphereVirtualDiskVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'storagePolicyID': obj.storagePolicyId, - 'storagePolicyName': obj.storagePolicyName, - 'volumePath': obj.volumePath, + fsType: obj.fsType, + storagePolicyID: obj.storagePolicyId, + storagePolicyName: obj.storagePolicyName, + volumePath: obj.volumePath, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -26980,22 +29962,28 @@ export interface TypedLocalObjectReference { * @schema io.k8s.api.core.v1.TypedLocalObjectReference#name */ readonly name: string; - } /** * Converts an object of type 'TypedLocalObjectReference' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TypedLocalObjectReference(obj: TypedLocalObjectReference | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TypedLocalObjectReference( + obj: TypedLocalObjectReference | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroup': obj.apiGroup, - 'kind': obj.kind, - 'name': obj.name, + apiGroup: obj.apiGroup, + kind: obj.kind, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27025,22 +30013,28 @@ export interface Affinity { * @schema io.k8s.api.core.v1.Affinity#podAntiAffinity */ readonly podAntiAffinity?: PodAntiAffinity; - } /** * Converts an object of type 'Affinity' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Affinity(obj: Affinity | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Affinity( + obj: Affinity | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nodeAffinity': toJson_NodeAffinity(obj.nodeAffinity), - 'podAffinity': toJson_PodAffinity(obj.podAffinity), - 'podAntiAffinity': toJson_PodAntiAffinity(obj.podAntiAffinity), + nodeAffinity: toJson_NodeAffinity(obj.nodeAffinity), + podAffinity: toJson_PodAffinity(obj.podAffinity), + podAntiAffinity: toJson_PodAntiAffinity(obj.podAntiAffinity), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27209,41 +30203,47 @@ export interface Container { * @schema io.k8s.api.core.v1.Container#workingDir */ readonly workingDir?: string; - } /** * Converts an object of type 'Container' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Container(obj: Container | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Container( + obj: Container | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'args': obj.args?.map(y => y), - 'command': obj.command?.map(y => y), - 'env': obj.env?.map(y => toJson_EnvVar(y)), - 'envFrom': obj.envFrom?.map(y => toJson_EnvFromSource(y)), - 'image': obj.image, - 'imagePullPolicy': obj.imagePullPolicy, - 'lifecycle': toJson_Lifecycle(obj.lifecycle), - 'livenessProbe': toJson_Probe(obj.livenessProbe), - 'name': obj.name, - 'ports': obj.ports?.map(y => toJson_ContainerPort(y)), - 'readinessProbe': toJson_Probe(obj.readinessProbe), - 'resources': toJson_ResourceRequirements(obj.resources), - 'securityContext': toJson_SecurityContext(obj.securityContext), - 'startupProbe': toJson_Probe(obj.startupProbe), - 'stdin': obj.stdin, - 'stdinOnce': obj.stdinOnce, - 'terminationMessagePath': obj.terminationMessagePath, - 'terminationMessagePolicy': obj.terminationMessagePolicy, - 'tty': obj.tty, - 'volumeDevices': obj.volumeDevices?.map(y => toJson_VolumeDevice(y)), - 'volumeMounts': obj.volumeMounts?.map(y => toJson_VolumeMount(y)), - 'workingDir': obj.workingDir, + args: obj.args?.map((y) => y), + command: obj.command?.map((y) => y), + env: obj.env?.map((y) => toJson_EnvVar(y)), + envFrom: obj.envFrom?.map((y) => toJson_EnvFromSource(y)), + image: obj.image, + imagePullPolicy: obj.imagePullPolicy, + lifecycle: toJson_Lifecycle(obj.lifecycle), + livenessProbe: toJson_Probe(obj.livenessProbe), + name: obj.name, + ports: obj.ports?.map((y) => toJson_ContainerPort(y)), + readinessProbe: toJson_Probe(obj.readinessProbe), + resources: toJson_ResourceRequirements(obj.resources), + securityContext: toJson_SecurityContext(obj.securityContext), + startupProbe: toJson_Probe(obj.startupProbe), + stdin: obj.stdin, + stdinOnce: obj.stdinOnce, + terminationMessagePath: obj.terminationMessagePath, + terminationMessagePolicy: obj.terminationMessagePolicy, + tty: obj.tty, + volumeDevices: obj.volumeDevices?.map((y) => toJson_VolumeDevice(y)), + volumeMounts: obj.volumeMounts?.map((y) => toJson_VolumeMount(y)), + workingDir: obj.workingDir, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27273,22 +30273,28 @@ export interface PodDnsConfig { * @schema io.k8s.api.core.v1.PodDNSConfig#searches */ readonly searches?: string[]; - } /** * Converts an object of type 'PodDnsConfig' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodDnsConfig(obj: PodDnsConfig | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodDnsConfig( + obj: PodDnsConfig | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nameservers': obj.nameservers?.map(y => y), - 'options': obj.options?.map(y => toJson_PodDnsConfigOption(y)), - 'searches': obj.searches?.map(y => y), + nameservers: obj.nameservers?.map((y) => y), + options: obj.options?.map((y) => toJson_PodDnsConfigOption(y)), + searches: obj.searches?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27311,21 +30317,27 @@ export interface HostAlias { * @schema io.k8s.api.core.v1.HostAlias#ip */ readonly ip?: string; - } /** * Converts an object of type 'HostAlias' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HostAlias(obj: HostAlias | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HostAlias( + obj: HostAlias | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'hostnames': obj.hostnames?.map(y => y), - 'ip': obj.ip, + hostnames: obj.hostnames?.map((y) => y), + ip: obj.ip, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27341,20 +30353,26 @@ export interface PodReadinessGate { * @schema io.k8s.api.core.v1.PodReadinessGate#conditionType */ readonly conditionType: string; - } /** * Converts an object of type 'PodReadinessGate' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodReadinessGate(obj: PodReadinessGate | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodReadinessGate( + obj: PodReadinessGate | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'conditionType': obj.conditionType, + conditionType: obj.conditionType, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27438,29 +30456,35 @@ export interface PodSecurityContext { * @schema io.k8s.api.core.v1.PodSecurityContext#windowsOptions */ readonly windowsOptions?: WindowsSecurityContextOptions; - } /** * Converts an object of type 'PodSecurityContext' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodSecurityContext(obj: PodSecurityContext | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodSecurityContext( + obj: PodSecurityContext | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsGroup': obj.fsGroup, - 'fsGroupChangePolicy': obj.fsGroupChangePolicy, - 'runAsGroup': obj.runAsGroup, - 'runAsNonRoot': obj.runAsNonRoot, - 'runAsUser': obj.runAsUser, - 'seLinuxOptions': toJson_SeLinuxOptions(obj.seLinuxOptions), - 'seccompProfile': toJson_SeccompProfile(obj.seccompProfile), - 'supplementalGroups': obj.supplementalGroups?.map(y => y), - 'sysctls': obj.sysctls?.map(y => toJson_Sysctl(y)), - 'windowsOptions': toJson_WindowsSecurityContextOptions(obj.windowsOptions), + fsGroup: obj.fsGroup, + fsGroupChangePolicy: obj.fsGroupChangePolicy, + runAsGroup: obj.runAsGroup, + runAsNonRoot: obj.runAsNonRoot, + runAsUser: obj.runAsUser, + seLinuxOptions: toJson_SeLinuxOptions(obj.seLinuxOptions), + seccompProfile: toJson_SeccompProfile(obj.seccompProfile), + supplementalGroups: obj.supplementalGroups?.map((y) => y), + sysctls: obj.sysctls?.map((y) => toJson_Sysctl(y)), + windowsOptions: toJson_WindowsSecurityContextOptions(obj.windowsOptions), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27505,24 +30529,30 @@ export interface Toleration { * @schema io.k8s.api.core.v1.Toleration#value */ readonly value?: string; - } /** * Converts an object of type 'Toleration' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Toleration(obj: Toleration | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Toleration( + obj: Toleration | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'effect': obj.effect, - 'key': obj.key, - 'operator': obj.operator, - 'tolerationSeconds': obj.tolerationSeconds, - 'value': obj.value, + effect: obj.effect, + key: obj.key, + operator: obj.operator, + tolerationSeconds: obj.tolerationSeconds, + value: obj.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27562,23 +30592,29 @@ export interface TopologySpreadConstraint { * @schema io.k8s.api.core.v1.TopologySpreadConstraint#whenUnsatisfiable */ readonly whenUnsatisfiable: string; - } /** * Converts an object of type 'TopologySpreadConstraint' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TopologySpreadConstraint(obj: TopologySpreadConstraint | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TopologySpreadConstraint( + obj: TopologySpreadConstraint | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'labelSelector': toJson_LabelSelector(obj.labelSelector), - 'maxSkew': obj.maxSkew, - 'topologyKey': obj.topologyKey, - 'whenUnsatisfiable': obj.whenUnsatisfiable, + labelSelector: toJson_LabelSelector(obj.labelSelector), + maxSkew: obj.maxSkew, + topologyKey: obj.topologyKey, + whenUnsatisfiable: obj.whenUnsatisfiable, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27812,49 +30848,63 @@ export interface Volume { * @schema io.k8s.api.core.v1.Volume#vsphereVolume */ readonly vsphereVolume?: VsphereVirtualDiskVolumeSource; - } /** * Converts an object of type 'Volume' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Volume(obj: Volume | undefined): Record | undefined { - if (obj === undefined) { return undefined; } - const result = { - 'awsElasticBlockStore': toJson_AwsElasticBlockStoreVolumeSource(obj.awsElasticBlockStore), - 'azureDisk': toJson_AzureDiskVolumeSource(obj.azureDisk), - 'azureFile': toJson_AzureFileVolumeSource(obj.azureFile), - 'cephfs': toJson_CephFsVolumeSource(obj.cephfs), - 'cinder': toJson_CinderVolumeSource(obj.cinder), - 'configMap': toJson_ConfigMapVolumeSource(obj.configMap), - 'csi': toJson_CsiVolumeSource(obj.csi), - 'downwardAPI': toJson_DownwardApiVolumeSource(obj.downwardApi), - 'emptyDir': toJson_EmptyDirVolumeSource(obj.emptyDir), - 'ephemeral': toJson_EphemeralVolumeSource(obj.ephemeral), - 'fc': toJson_FcVolumeSource(obj.fc), - 'flexVolume': toJson_FlexVolumeSource(obj.flexVolume), - 'flocker': toJson_FlockerVolumeSource(obj.flocker), - 'gcePersistentDisk': toJson_GcePersistentDiskVolumeSource(obj.gcePersistentDisk), - 'gitRepo': toJson_GitRepoVolumeSource(obj.gitRepo), - 'glusterfs': toJson_GlusterfsVolumeSource(obj.glusterfs), - 'hostPath': toJson_HostPathVolumeSource(obj.hostPath), - 'iscsi': toJson_IscsiVolumeSource(obj.iscsi), - 'name': obj.name, - 'nfs': toJson_NfsVolumeSource(obj.nfs), - 'persistentVolumeClaim': toJson_PersistentVolumeClaimVolumeSource(obj.persistentVolumeClaim), - 'photonPersistentDisk': toJson_PhotonPersistentDiskVolumeSource(obj.photonPersistentDisk), - 'portworxVolume': toJson_PortworxVolumeSource(obj.portworxVolume), - 'projected': toJson_ProjectedVolumeSource(obj.projected), - 'quobyte': toJson_QuobyteVolumeSource(obj.quobyte), - 'rbd': toJson_RbdVolumeSource(obj.rbd), - 'scaleIO': toJson_ScaleIoVolumeSource(obj.scaleIo), - 'secret': toJson_SecretVolumeSource(obj.secret), - 'storageos': toJson_StorageOsVolumeSource(obj.storageos), - 'vsphereVolume': toJson_VsphereVirtualDiskVolumeSource(obj.vsphereVolume), - }; - // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); +export function toJson_Volume( + obj: Volume | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } + const result = { + awsElasticBlockStore: toJson_AwsElasticBlockStoreVolumeSource( + obj.awsElasticBlockStore + ), + azureDisk: toJson_AzureDiskVolumeSource(obj.azureDisk), + azureFile: toJson_AzureFileVolumeSource(obj.azureFile), + cephfs: toJson_CephFsVolumeSource(obj.cephfs), + cinder: toJson_CinderVolumeSource(obj.cinder), + configMap: toJson_ConfigMapVolumeSource(obj.configMap), + csi: toJson_CsiVolumeSource(obj.csi), + downwardAPI: toJson_DownwardApiVolumeSource(obj.downwardApi), + emptyDir: toJson_EmptyDirVolumeSource(obj.emptyDir), + ephemeral: toJson_EphemeralVolumeSource(obj.ephemeral), + fc: toJson_FcVolumeSource(obj.fc), + flexVolume: toJson_FlexVolumeSource(obj.flexVolume), + flocker: toJson_FlockerVolumeSource(obj.flocker), + gcePersistentDisk: toJson_GcePersistentDiskVolumeSource( + obj.gcePersistentDisk + ), + gitRepo: toJson_GitRepoVolumeSource(obj.gitRepo), + glusterfs: toJson_GlusterfsVolumeSource(obj.glusterfs), + hostPath: toJson_HostPathVolumeSource(obj.hostPath), + iscsi: toJson_IscsiVolumeSource(obj.iscsi), + name: obj.name, + nfs: toJson_NfsVolumeSource(obj.nfs), + persistentVolumeClaim: toJson_PersistentVolumeClaimVolumeSource( + obj.persistentVolumeClaim + ), + photonPersistentDisk: toJson_PhotonPersistentDiskVolumeSource( + obj.photonPersistentDisk + ), + portworxVolume: toJson_PortworxVolumeSource(obj.portworxVolume), + projected: toJson_ProjectedVolumeSource(obj.projected), + quobyte: toJson_QuobyteVolumeSource(obj.quobyte), + rbd: toJson_RbdVolumeSource(obj.rbd), + scaleIO: toJson_ScaleIoVolumeSource(obj.scaleIo), + secret: toJson_SecretVolumeSource(obj.secret), + storageos: toJson_StorageOsVolumeSource(obj.storageos), + vsphereVolume: toJson_VsphereVirtualDiskVolumeSource(obj.vsphereVolume), + }; + // filter undefined values + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27870,20 +30920,28 @@ export interface ScopeSelector { * @schema io.k8s.api.core.v1.ScopeSelector#matchExpressions */ readonly matchExpressions?: ScopedResourceSelectorRequirement[]; - } /** * Converts an object of type 'ScopeSelector' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ScopeSelector(obj: ScopeSelector | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ScopeSelector( + obj: ScopeSelector | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'matchExpressions': obj.matchExpressions?.map(y => toJson_ScopedResourceSelectorRequirement(y)), + matchExpressions: obj.matchExpressions?.map((y) => + toJson_ScopedResourceSelectorRequirement(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27935,25 +30993,31 @@ export interface ServicePort { * @schema io.k8s.api.core.v1.ServicePort#targetPort */ readonly targetPort?: IntOrString; - } /** * Converts an object of type 'ServicePort' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ServicePort(obj: ServicePort | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ServicePort( + obj: ServicePort | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'appProtocol': obj.appProtocol, - 'name': obj.name, - 'nodePort': obj.nodePort, - 'port': obj.port, - 'protocol': obj.protocol, - 'targetPort': obj.targetPort?.value, + appProtocol: obj.appProtocol, + name: obj.name, + nodePort: obj.nodePort, + port: obj.port, + protocol: obj.protocol, + targetPort: obj.targetPort?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -27969,20 +31033,26 @@ export interface SessionAffinityConfig { * @schema io.k8s.api.core.v1.SessionAffinityConfig#clientIP */ readonly clientIp?: ClientIpConfig; - } /** * Converts an object of type 'SessionAffinityConfig' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SessionAffinityConfig(obj: SessionAffinityConfig | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SessionAffinityConfig( + obj: SessionAffinityConfig | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'clientIP': toJson_ClientIpConfig(obj.clientIp), + clientIP: toJson_ClientIpConfig(obj.clientIp), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28012,22 +31082,28 @@ export interface EndpointConditions { * @schema io.k8s.api.discovery.v1.EndpointConditions#terminating */ readonly terminating?: boolean; - } /** * Converts an object of type 'EndpointConditions' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EndpointConditions(obj: EndpointConditions | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EndpointConditions( + obj: EndpointConditions | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'ready': obj.ready, - 'serving': obj.serving, - 'terminating': obj.terminating, + ready: obj.ready, + serving: obj.serving, + terminating: obj.terminating, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28043,20 +31119,26 @@ export interface EndpointHints { * @schema io.k8s.api.discovery.v1.EndpointHints#forZones */ readonly forZones?: ForZone[]; - } /** * Converts an object of type 'EndpointHints' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EndpointHints(obj: EndpointHints | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EndpointHints( + obj: EndpointHints | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'forZones': obj.forZones?.map(y => toJson_ForZone(y)), + forZones: obj.forZones?.map((y) => toJson_ForZone(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28086,22 +31168,28 @@ export interface EndpointConditionsV1Beta1 { * @schema io.k8s.api.discovery.v1beta1.EndpointConditions#terminating */ readonly terminating?: boolean; - } /** * Converts an object of type 'EndpointConditionsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EndpointConditionsV1Beta1(obj: EndpointConditionsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EndpointConditionsV1Beta1( + obj: EndpointConditionsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'ready': obj.ready, - 'serving': obj.serving, - 'terminating': obj.terminating, + ready: obj.ready, + serving: obj.serving, + terminating: obj.terminating, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28117,20 +31205,26 @@ export interface EndpointHintsV1Beta1 { * @schema io.k8s.api.discovery.v1beta1.EndpointHints#forZones */ readonly forZones?: ForZoneV1Beta1[]; - } /** * Converts an object of type 'EndpointHintsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EndpointHintsV1Beta1(obj: EndpointHintsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EndpointHintsV1Beta1( + obj: EndpointHintsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'forZones': obj.forZones?.map(y => toJson_ForZoneV1Beta1(y)), + forZones: obj.forZones?.map((y) => toJson_ForZoneV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28160,22 +31254,28 @@ export interface IngressBackendV1Beta1 { * @schema io.k8s.api.networking.v1beta1.IngressBackend#servicePort */ readonly servicePort?: IntOrString; - } /** * Converts an object of type 'IngressBackendV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressBackendV1Beta1(obj: IngressBackendV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressBackendV1Beta1( + obj: IngressBackendV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'resource': toJson_TypedLocalObjectReference(obj.resource), - 'serviceName': obj.serviceName, - 'servicePort': obj.servicePort?.value, + resource: toJson_TypedLocalObjectReference(obj.resource), + serviceName: obj.serviceName, + servicePort: obj.servicePort?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28203,21 +31303,27 @@ export interface IngressRuleV1Beta1 { * @schema io.k8s.api.networking.v1beta1.IngressRule#http */ readonly http?: HttpIngressRuleValueV1Beta1; - } /** * Converts an object of type 'IngressRuleV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressRuleV1Beta1(obj: IngressRuleV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressRuleV1Beta1( + obj: IngressRuleV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'host': obj.host, - 'http': toJson_HttpIngressRuleValueV1Beta1(obj.http), + host: obj.host, + http: toJson_HttpIngressRuleValueV1Beta1(obj.http), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28241,21 +31347,27 @@ export interface IngressTlsv1Beta1 { * @schema io.k8s.api.networking.v1beta1.IngressTLS#secretName */ readonly secretName?: string; - } /** * Converts an object of type 'IngressTlsv1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressTlsv1Beta1(obj: IngressTlsv1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressTlsv1Beta1( + obj: IngressTlsv1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'hosts': obj.hosts?.map(y => y), - 'secretName': obj.secretName, + hosts: obj.hosts?.map((y) => y), + secretName: obj.secretName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28271,20 +31383,26 @@ export interface FlowDistinguisherMethodV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.FlowDistinguisherMethod#type */ readonly type: string; - } /** * Converts an object of type 'FlowDistinguisherMethodV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_FlowDistinguisherMethodV1Beta1(obj: FlowDistinguisherMethodV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_FlowDistinguisherMethodV1Beta1( + obj: FlowDistinguisherMethodV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'type': obj.type, + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28300,20 +31418,26 @@ export interface PriorityLevelConfigurationReferenceV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.PriorityLevelConfigurationReference#name */ readonly name: string; - } /** * Converts an object of type 'PriorityLevelConfigurationReferenceV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PriorityLevelConfigurationReferenceV1Beta1(obj: PriorityLevelConfigurationReferenceV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PriorityLevelConfigurationReferenceV1Beta1( + obj: PriorityLevelConfigurationReferenceV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28343,22 +31467,32 @@ export interface PolicyRulesWithSubjectsV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.PolicyRulesWithSubjects#subjects */ readonly subjects: SubjectV1Beta1[]; - } /** * Converts an object of type 'PolicyRulesWithSubjectsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PolicyRulesWithSubjectsV1Beta1(obj: PolicyRulesWithSubjectsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PolicyRulesWithSubjectsV1Beta1( + obj: PolicyRulesWithSubjectsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nonResourceRules': obj.nonResourceRules?.map(y => toJson_NonResourcePolicyRuleV1Beta1(y)), - 'resourceRules': obj.resourceRules?.map(y => toJson_ResourcePolicyRuleV1Beta1(y)), - 'subjects': obj.subjects?.map(y => toJson_SubjectV1Beta1(y)), + nonResourceRules: obj.nonResourceRules?.map((y) => + toJson_NonResourcePolicyRuleV1Beta1(y) + ), + resourceRules: obj.resourceRules?.map((y) => + toJson_ResourcePolicyRuleV1Beta1(y) + ), + subjects: obj.subjects?.map((y) => toJson_SubjectV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28387,21 +31521,27 @@ export interface LimitedPriorityLevelConfigurationV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.LimitedPriorityLevelConfiguration#limitResponse */ readonly limitResponse?: LimitResponseV1Beta1; - } /** * Converts an object of type 'LimitedPriorityLevelConfigurationV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LimitedPriorityLevelConfigurationV1Beta1(obj: LimitedPriorityLevelConfigurationV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_LimitedPriorityLevelConfigurationV1Beta1( + obj: LimitedPriorityLevelConfigurationV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'assuredConcurrencyShares': obj.assuredConcurrencyShares, - 'limitResponse': toJson_LimitResponseV1Beta1(obj.limitResponse), + assuredConcurrencyShares: obj.assuredConcurrencyShares, + limitResponse: toJson_LimitResponseV1Beta1(obj.limitResponse), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28424,21 +31564,27 @@ export interface IngressBackend { * @schema io.k8s.api.networking.v1.IngressBackend#service */ readonly service?: IngressServiceBackend; - } /** * Converts an object of type 'IngressBackend' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressBackend(obj: IngressBackend | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressBackend( + obj: IngressBackend | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'resource': toJson_TypedLocalObjectReference(obj.resource), - 'service': toJson_IngressServiceBackend(obj.service), + resource: toJson_TypedLocalObjectReference(obj.resource), + service: toJson_IngressServiceBackend(obj.service), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28466,21 +31612,27 @@ export interface IngressRule { * @schema io.k8s.api.networking.v1.IngressRule#http */ readonly http?: HttpIngressRuleValue; - } /** * Converts an object of type 'IngressRule' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressRule(obj: IngressRule | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressRule( + obj: IngressRule | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'host': obj.host, - 'http': toJson_HttpIngressRuleValue(obj.http), + host: obj.host, + http: toJson_HttpIngressRuleValue(obj.http), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28504,21 +31656,27 @@ export interface IngressTls { * @schema io.k8s.api.networking.v1.IngressTLS#secretName */ readonly secretName?: string; - } /** * Converts an object of type 'IngressTls' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressTls(obj: IngressTls | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressTls( + obj: IngressTls | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'hosts': obj.hosts?.map(y => y), - 'secretName': obj.secretName, + hosts: obj.hosts?.map((y) => y), + secretName: obj.secretName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28562,24 +31720,30 @@ export interface IngressClassParametersReference { * @schema io.k8s.api.networking.v1.IngressClassParametersReference#scope */ readonly scope?: string; - } /** * Converts an object of type 'IngressClassParametersReference' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressClassParametersReference(obj: IngressClassParametersReference | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressClassParametersReference( + obj: IngressClassParametersReference | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroup': obj.apiGroup, - 'kind': obj.kind, - 'name': obj.name, - 'namespace': obj.namespace, - 'scope': obj.scope, + apiGroup: obj.apiGroup, + kind: obj.kind, + name: obj.name, + namespace: obj.namespace, + scope: obj.scope, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28602,21 +31766,27 @@ export interface NetworkPolicyEgressRule { * @schema io.k8s.api.networking.v1.NetworkPolicyEgressRule#to */ readonly to?: NetworkPolicyPeer[]; - } /** * Converts an object of type 'NetworkPolicyEgressRule' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NetworkPolicyEgressRule(obj: NetworkPolicyEgressRule | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NetworkPolicyEgressRule( + obj: NetworkPolicyEgressRule | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'ports': obj.ports?.map(y => toJson_NetworkPolicyPort(y)), - 'to': obj.to?.map(y => toJson_NetworkPolicyPeer(y)), + ports: obj.ports?.map((y) => toJson_NetworkPolicyPort(y)), + to: obj.to?.map((y) => toJson_NetworkPolicyPeer(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28639,21 +31809,27 @@ export interface NetworkPolicyIngressRule { * @schema io.k8s.api.networking.v1.NetworkPolicyIngressRule#ports */ readonly ports?: NetworkPolicyPort[]; - } /** * Converts an object of type 'NetworkPolicyIngressRule' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NetworkPolicyIngressRule(obj: NetworkPolicyIngressRule | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NetworkPolicyIngressRule( + obj: NetworkPolicyIngressRule | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'from': obj.from?.map(y => toJson_NetworkPolicyPeer(y)), - 'ports': obj.ports?.map(y => toJson_NetworkPolicyPort(y)), + from: obj.from?.map((y) => toJson_NetworkPolicyPeer(y)), + ports: obj.ports?.map((y) => toJson_NetworkPolicyPort(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28697,24 +31873,30 @@ export interface IngressClassParametersReferenceV1Beta1 { * @schema io.k8s.api.networking.v1beta1.IngressClassParametersReference#scope */ readonly scope?: string; - } /** * Converts an object of type 'IngressClassParametersReferenceV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressClassParametersReferenceV1Beta1(obj: IngressClassParametersReferenceV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressClassParametersReferenceV1Beta1( + obj: IngressClassParametersReferenceV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroup': obj.apiGroup, - 'kind': obj.kind, - 'name': obj.name, - 'namespace': obj.namespace, - 'scope': obj.scope, + apiGroup: obj.apiGroup, + kind: obj.kind, + name: obj.name, + namespace: obj.namespace, + scope: obj.scope, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28730,20 +31912,32 @@ export interface OverheadV1Alpha1 { * @schema io.k8s.api.node.v1alpha1.Overhead#podFixed */ readonly podFixed?: { [key: string]: Quantity }; - } /** * Converts an object of type 'OverheadV1Alpha1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_OverheadV1Alpha1(obj: OverheadV1Alpha1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_OverheadV1Alpha1( + obj: OverheadV1Alpha1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'podFixed': ((obj.podFixed) === undefined) ? undefined : (Object.entries(obj.podFixed).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1]?.value }), {})), + podFixed: + obj.podFixed === undefined + ? undefined + : Object.entries(obj.podFixed).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1]?.value }), + {} + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28766,21 +31960,33 @@ export interface SchedulingV1Alpha1 { * @schema io.k8s.api.node.v1alpha1.Scheduling#tolerations */ readonly tolerations?: Toleration[]; - } /** * Converts an object of type 'SchedulingV1Alpha1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SchedulingV1Alpha1(obj: SchedulingV1Alpha1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SchedulingV1Alpha1( + obj: SchedulingV1Alpha1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nodeSelector': ((obj.nodeSelector) === undefined) ? undefined : (Object.entries(obj.nodeSelector).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'tolerations': obj.tolerations?.map(y => toJson_Toleration(y)), + nodeSelector: + obj.nodeSelector === undefined + ? undefined + : Object.entries(obj.nodeSelector).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + tolerations: obj.tolerations?.map((y) => toJson_Toleration(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28794,8 +32000,7 @@ export class IntOrString { public static fromNumber(value: number): IntOrString { return new IntOrString(value); } - private constructor(public readonly value: any) { - } + private constructor(public readonly value: any) {} } /** @@ -28805,7 +32010,7 @@ export class IntOrString { */ export enum IoK8SApimachineryPkgApisMetaV1DeleteOptionsKind { /** DeleteOptions */ - DELETE_OPTIONS = 'DeleteOptions', + DELETE_OPTIONS = "DeleteOptions", } /** @@ -28827,21 +32032,27 @@ export interface Preconditions { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.Preconditions#uid */ readonly uid?: string; - } /** * Converts an object of type 'Preconditions' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Preconditions(obj: Preconditions | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Preconditions( + obj: Preconditions | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'resourceVersion': obj.resourceVersion, - 'uid': obj.uid, + resourceVersion: obj.resourceVersion, + uid: obj.uid, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28857,20 +32068,26 @@ export interface AllowedCsiDriverV1Beta1 { * @schema io.k8s.api.policy.v1beta1.AllowedCSIDriver#name */ readonly name: string; - } /** * Converts an object of type 'AllowedCsiDriverV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AllowedCsiDriverV1Beta1(obj: AllowedCsiDriverV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AllowedCsiDriverV1Beta1( + obj: AllowedCsiDriverV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28886,20 +32103,26 @@ export interface AllowedFlexVolumeV1Beta1 { * @schema io.k8s.api.policy.v1beta1.AllowedFlexVolume#driver */ readonly driver: string; - } /** * Converts an object of type 'AllowedFlexVolumeV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AllowedFlexVolumeV1Beta1(obj: AllowedFlexVolumeV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AllowedFlexVolumeV1Beta1( + obj: AllowedFlexVolumeV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'driver': obj.driver, + driver: obj.driver, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28924,21 +32147,27 @@ export interface AllowedHostPathV1Beta1 { * @schema io.k8s.api.policy.v1beta1.AllowedHostPath#readOnly */ readonly readOnly?: boolean; - } /** * Converts an object of type 'AllowedHostPathV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AllowedHostPathV1Beta1(obj: AllowedHostPathV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AllowedHostPathV1Beta1( + obj: AllowedHostPathV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'pathPrefix': obj.pathPrefix, - 'readOnly': obj.readOnly, + pathPrefix: obj.pathPrefix, + readOnly: obj.readOnly, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28961,21 +32190,27 @@ export interface FsGroupStrategyOptionsV1Beta1 { * @schema io.k8s.api.policy.v1beta1.FSGroupStrategyOptions#rule */ readonly rule?: string; - } /** * Converts an object of type 'FsGroupStrategyOptionsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_FsGroupStrategyOptionsV1Beta1(obj: FsGroupStrategyOptionsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_FsGroupStrategyOptionsV1Beta1( + obj: FsGroupStrategyOptionsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'ranges': obj.ranges?.map(y => toJson_IdRangeV1Beta1(y)), - 'rule': obj.rule, + ranges: obj.ranges?.map((y) => toJson_IdRangeV1Beta1(y)), + rule: obj.rule, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -28998,21 +32233,27 @@ export interface HostPortRangeV1Beta1 { * @schema io.k8s.api.policy.v1beta1.HostPortRange#min */ readonly min: number; - } /** * Converts an object of type 'HostPortRangeV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HostPortRangeV1Beta1(obj: HostPortRangeV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HostPortRangeV1Beta1( + obj: HostPortRangeV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'max': obj.max, - 'min': obj.min, + max: obj.max, + min: obj.min, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29035,21 +32276,27 @@ export interface RunAsGroupStrategyOptionsV1Beta1 { * @schema io.k8s.api.policy.v1beta1.RunAsGroupStrategyOptions#rule */ readonly rule: string; - } /** * Converts an object of type 'RunAsGroupStrategyOptionsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RunAsGroupStrategyOptionsV1Beta1(obj: RunAsGroupStrategyOptionsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RunAsGroupStrategyOptionsV1Beta1( + obj: RunAsGroupStrategyOptionsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'ranges': obj.ranges?.map(y => toJson_IdRangeV1Beta1(y)), - 'rule': obj.rule, + ranges: obj.ranges?.map((y) => toJson_IdRangeV1Beta1(y)), + rule: obj.rule, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29072,21 +32319,27 @@ export interface RunAsUserStrategyOptionsV1Beta1 { * @schema io.k8s.api.policy.v1beta1.RunAsUserStrategyOptions#rule */ readonly rule: string; - } /** * Converts an object of type 'RunAsUserStrategyOptionsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RunAsUserStrategyOptionsV1Beta1(obj: RunAsUserStrategyOptionsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RunAsUserStrategyOptionsV1Beta1( + obj: RunAsUserStrategyOptionsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'ranges': obj.ranges?.map(y => toJson_IdRangeV1Beta1(y)), - 'rule': obj.rule, + ranges: obj.ranges?.map((y) => toJson_IdRangeV1Beta1(y)), + rule: obj.rule, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29109,21 +32362,27 @@ export interface RuntimeClassStrategyOptionsV1Beta1 { * @schema io.k8s.api.policy.v1beta1.RuntimeClassStrategyOptions#defaultRuntimeClassName */ readonly defaultRuntimeClassName?: string; - } /** * Converts an object of type 'RuntimeClassStrategyOptionsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RuntimeClassStrategyOptionsV1Beta1(obj: RuntimeClassStrategyOptionsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RuntimeClassStrategyOptionsV1Beta1( + obj: RuntimeClassStrategyOptionsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'allowedRuntimeClassNames': obj.allowedRuntimeClassNames?.map(y => y), - 'defaultRuntimeClassName': obj.defaultRuntimeClassName, + allowedRuntimeClassNames: obj.allowedRuntimeClassNames?.map((y) => y), + defaultRuntimeClassName: obj.defaultRuntimeClassName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29146,21 +32405,27 @@ export interface SeLinuxStrategyOptionsV1Beta1 { * @schema io.k8s.api.policy.v1beta1.SELinuxStrategyOptions#seLinuxOptions */ readonly seLinuxOptions?: SeLinuxOptions; - } /** * Converts an object of type 'SeLinuxStrategyOptionsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SeLinuxStrategyOptionsV1Beta1(obj: SeLinuxStrategyOptionsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SeLinuxStrategyOptionsV1Beta1( + obj: SeLinuxStrategyOptionsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'rule': obj.rule, - 'seLinuxOptions': toJson_SeLinuxOptions(obj.seLinuxOptions), + rule: obj.rule, + seLinuxOptions: toJson_SeLinuxOptions(obj.seLinuxOptions), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29183,21 +32448,27 @@ export interface SupplementalGroupsStrategyOptionsV1Beta1 { * @schema io.k8s.api.policy.v1beta1.SupplementalGroupsStrategyOptions#rule */ readonly rule?: string; - } /** * Converts an object of type 'SupplementalGroupsStrategyOptionsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SupplementalGroupsStrategyOptionsV1Beta1(obj: SupplementalGroupsStrategyOptionsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SupplementalGroupsStrategyOptionsV1Beta1( + obj: SupplementalGroupsStrategyOptionsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'ranges': obj.ranges?.map(y => toJson_IdRangeV1Beta1(y)), - 'rule': obj.rule, + ranges: obj.ranges?.map((y) => toJson_IdRangeV1Beta1(y)), + rule: obj.rule, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29220,21 +32491,27 @@ export interface TokenRequest { * @schema io.k8s.api.storage.v1.TokenRequest#expirationSeconds */ readonly expirationSeconds?: number; - } /** * Converts an object of type 'TokenRequest' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TokenRequest(obj: TokenRequest | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TokenRequest( + obj: TokenRequest | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'audience': obj.audience, - 'expirationSeconds': obj.expirationSeconds, + audience: obj.audience, + expirationSeconds: obj.expirationSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29271,23 +32548,29 @@ export interface CsiNodeDriver { * @schema io.k8s.api.storage.v1.CSINodeDriver#topologyKeys */ readonly topologyKeys?: string[]; - } /** * Converts an object of type 'CsiNodeDriver' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CsiNodeDriver(obj: CsiNodeDriver | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CsiNodeDriver( + obj: CsiNodeDriver | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'allocatable': toJson_VolumeNodeResources(obj.allocatable), - 'name': obj.name, - 'nodeID': obj.nodeId, - 'topologyKeys': obj.topologyKeys?.map(y => y), + allocatable: toJson_VolumeNodeResources(obj.allocatable), + name: obj.name, + nodeID: obj.nodeId, + topologyKeys: obj.topologyKeys?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29310,21 +32593,27 @@ export interface TopologySelectorLabelRequirement { * @schema io.k8s.api.core.v1.TopologySelectorLabelRequirement#values */ readonly values: string[]; - } /** * Converts an object of type 'TopologySelectorLabelRequirement' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TopologySelectorLabelRequirement(obj: TopologySelectorLabelRequirement | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TopologySelectorLabelRequirement( + obj: TopologySelectorLabelRequirement | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'key': obj.key, - 'values': obj.values?.map(y => y), + key: obj.key, + values: obj.values?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29347,21 +32636,27 @@ export interface VolumeAttachmentSource { * @schema io.k8s.api.storage.v1.VolumeAttachmentSource#persistentVolumeName */ readonly persistentVolumeName?: string; - } /** * Converts an object of type 'VolumeAttachmentSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeAttachmentSource(obj: VolumeAttachmentSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeAttachmentSource( + obj: VolumeAttachmentSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'inlineVolumeSpec': toJson_PersistentVolumeSpec(obj.inlineVolumeSpec), - 'persistentVolumeName': obj.persistentVolumeName, + inlineVolumeSpec: toJson_PersistentVolumeSpec(obj.inlineVolumeSpec), + persistentVolumeName: obj.persistentVolumeName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29391,22 +32686,28 @@ export interface LabelSelectorRequirement { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.LabelSelectorRequirement#values */ readonly values?: string[]; - } /** * Converts an object of type 'LabelSelectorRequirement' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LabelSelectorRequirement(obj: LabelSelectorRequirement | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_LabelSelectorRequirement( + obj: LabelSelectorRequirement | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'key': obj.key, - 'operator': obj.operator, - 'values': obj.values?.map(y => y), + key: obj.key, + operator: obj.operator, + values: obj.values?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29429,21 +32730,27 @@ export interface VolumeAttachmentSourceV1Alpha1 { * @schema io.k8s.api.storage.v1alpha1.VolumeAttachmentSource#persistentVolumeName */ readonly persistentVolumeName?: string; - } /** * Converts an object of type 'VolumeAttachmentSourceV1Alpha1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeAttachmentSourceV1Alpha1(obj: VolumeAttachmentSourceV1Alpha1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeAttachmentSourceV1Alpha1( + obj: VolumeAttachmentSourceV1Alpha1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'inlineVolumeSpec': toJson_PersistentVolumeSpec(obj.inlineVolumeSpec), - 'persistentVolumeName': obj.persistentVolumeName, + inlineVolumeSpec: toJson_PersistentVolumeSpec(obj.inlineVolumeSpec), + persistentVolumeName: obj.persistentVolumeName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29466,21 +32773,27 @@ export interface TokenRequestV1Beta1 { * @schema io.k8s.api.storage.v1beta1.TokenRequest#expirationSeconds */ readonly expirationSeconds?: number; - } /** * Converts an object of type 'TokenRequestV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TokenRequestV1Beta1(obj: TokenRequestV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TokenRequestV1Beta1( + obj: TokenRequestV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'audience': obj.audience, - 'expirationSeconds': obj.expirationSeconds, + audience: obj.audience, + expirationSeconds: obj.expirationSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29517,23 +32830,29 @@ export interface CsiNodeDriverV1Beta1 { * @schema io.k8s.api.storage.v1beta1.CSINodeDriver#topologyKeys */ readonly topologyKeys?: string[]; - } /** * Converts an object of type 'CsiNodeDriverV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CsiNodeDriverV1Beta1(obj: CsiNodeDriverV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CsiNodeDriverV1Beta1( + obj: CsiNodeDriverV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'allocatable': toJson_VolumeNodeResourcesV1Beta1(obj.allocatable), - 'name': obj.name, - 'nodeID': obj.nodeId, - 'topologyKeys': obj.topologyKeys?.map(y => y), + allocatable: toJson_VolumeNodeResourcesV1Beta1(obj.allocatable), + name: obj.name, + nodeID: obj.nodeId, + topologyKeys: obj.topologyKeys?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29556,21 +32875,27 @@ export interface VolumeAttachmentSourceV1Beta1 { * @schema io.k8s.api.storage.v1beta1.VolumeAttachmentSource#persistentVolumeName */ readonly persistentVolumeName?: string; - } /** * Converts an object of type 'VolumeAttachmentSourceV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeAttachmentSourceV1Beta1(obj: VolumeAttachmentSourceV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeAttachmentSourceV1Beta1( + obj: VolumeAttachmentSourceV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'inlineVolumeSpec': toJson_PersistentVolumeSpec(obj.inlineVolumeSpec), - 'persistentVolumeName': obj.persistentVolumeName, + inlineVolumeSpec: toJson_PersistentVolumeSpec(obj.inlineVolumeSpec), + persistentVolumeName: obj.persistentVolumeName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29594,21 +32919,27 @@ export interface CustomResourceConversion { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceConversion#webhook */ readonly webhook?: WebhookConversion; - } /** * Converts an object of type 'CustomResourceConversion' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceConversion(obj: CustomResourceConversion | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceConversion( + obj: CustomResourceConversion | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'strategy': obj.strategy, - 'webhook': toJson_WebhookConversion(obj.webhook), + strategy: obj.strategy, + webhook: toJson_WebhookConversion(obj.webhook), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29661,25 +32992,31 @@ export interface CustomResourceDefinitionNames { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceDefinitionNames#singular */ readonly singular?: string; - } /** * Converts an object of type 'CustomResourceDefinitionNames' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceDefinitionNames(obj: CustomResourceDefinitionNames | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceDefinitionNames( + obj: CustomResourceDefinitionNames | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'categories': obj.categories?.map(y => y), - 'kind': obj.kind, - 'listKind': obj.listKind, - 'plural': obj.plural, - 'shortNames': obj.shortNames?.map(y => y), - 'singular': obj.singular, + categories: obj.categories?.map((y) => y), + kind: obj.kind, + listKind: obj.listKind, + plural: obj.plural, + shortNames: obj.shortNames?.map((y) => y), + singular: obj.singular, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29745,27 +33082,35 @@ export interface CustomResourceDefinitionVersion { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceDefinitionVersion#subresources */ readonly subresources?: CustomResourceSubresources; - } /** * Converts an object of type 'CustomResourceDefinitionVersion' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceDefinitionVersion(obj: CustomResourceDefinitionVersion | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceDefinitionVersion( + obj: CustomResourceDefinitionVersion | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'additionalPrinterColumns': obj.additionalPrinterColumns?.map(y => toJson_CustomResourceColumnDefinition(y)), - 'deprecated': obj.deprecated, - 'deprecationWarning': obj.deprecationWarning, - 'name': obj.name, - 'schema': toJson_CustomResourceValidation(obj.schema), - 'served': obj.served, - 'storage': obj.storage, - 'subresources': toJson_CustomResourceSubresources(obj.subresources), + additionalPrinterColumns: obj.additionalPrinterColumns?.map((y) => + toJson_CustomResourceColumnDefinition(y) + ), + deprecated: obj.deprecated, + deprecationWarning: obj.deprecationWarning, + name: obj.name, + schema: toJson_CustomResourceValidation(obj.schema), + served: obj.served, + storage: obj.storage, + subresources: toJson_CustomResourceSubresources(obj.subresources), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29816,25 +33161,31 @@ export interface CustomResourceColumnDefinitionV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceColumnDefinition#type */ readonly type: string; - } /** * Converts an object of type 'CustomResourceColumnDefinitionV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceColumnDefinitionV1Beta1(obj: CustomResourceColumnDefinitionV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceColumnDefinitionV1Beta1( + obj: CustomResourceColumnDefinitionV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'JSONPath': obj.jsonPath, - 'description': obj.description, - 'format': obj.format, - 'name': obj.name, - 'priority': obj.priority, - 'type': obj.type, + JSONPath: obj.jsonPath, + description: obj.description, + format: obj.format, + name: obj.name, + priority: obj.priority, + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29866,22 +33217,30 @@ export interface CustomResourceConversionV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceConversion#webhookClientConfig */ readonly webhookClientConfig?: WebhookClientConfigV1Beta1; - } /** * Converts an object of type 'CustomResourceConversionV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceConversionV1Beta1(obj: CustomResourceConversionV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceConversionV1Beta1( + obj: CustomResourceConversionV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'conversionReviewVersions': obj.conversionReviewVersions?.map(y => y), - 'strategy': obj.strategy, - 'webhookClientConfig': toJson_WebhookClientConfigV1Beta1(obj.webhookClientConfig), + conversionReviewVersions: obj.conversionReviewVersions?.map((y) => y), + strategy: obj.strategy, + webhookClientConfig: toJson_WebhookClientConfigV1Beta1( + obj.webhookClientConfig + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29934,25 +33293,31 @@ export interface CustomResourceDefinitionNamesV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceDefinitionNames#singular */ readonly singular?: string; - } /** * Converts an object of type 'CustomResourceDefinitionNamesV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceDefinitionNamesV1Beta1(obj: CustomResourceDefinitionNamesV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceDefinitionNamesV1Beta1( + obj: CustomResourceDefinitionNamesV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'categories': obj.categories?.map(y => y), - 'kind': obj.kind, - 'listKind': obj.listKind, - 'plural': obj.plural, - 'shortNames': obj.shortNames?.map(y => y), - 'singular': obj.singular, + categories: obj.categories?.map((y) => y), + kind: obj.kind, + listKind: obj.listKind, + plural: obj.plural, + shortNames: obj.shortNames?.map((y) => y), + singular: obj.singular, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -29975,21 +33340,27 @@ export interface CustomResourceSubresourcesV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceSubresources#status */ readonly status?: any; - } /** * Converts an object of type 'CustomResourceSubresourcesV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceSubresourcesV1Beta1(obj: CustomResourceSubresourcesV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceSubresourcesV1Beta1( + obj: CustomResourceSubresourcesV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'scale': toJson_CustomResourceSubresourceScaleV1Beta1(obj.scale), - 'status': obj.status, + scale: toJson_CustomResourceSubresourceScaleV1Beta1(obj.scale), + status: obj.status, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30005,20 +33376,26 @@ export interface CustomResourceValidationV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceValidation#openAPIV3Schema */ readonly openApiv3Schema?: JsonSchemaPropsV1Beta1; - } /** * Converts an object of type 'CustomResourceValidationV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceValidationV1Beta1(obj: CustomResourceValidationV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceValidationV1Beta1( + obj: CustomResourceValidationV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'openAPIV3Schema': toJson_JsonSchemaPropsV1Beta1(obj.openApiv3Schema), + openAPIV3Schema: toJson_JsonSchemaPropsV1Beta1(obj.openApiv3Schema), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30084,27 +33461,35 @@ export interface CustomResourceDefinitionVersionV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceDefinitionVersion#subresources */ readonly subresources?: CustomResourceSubresourcesV1Beta1; - } /** * Converts an object of type 'CustomResourceDefinitionVersionV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceDefinitionVersionV1Beta1(obj: CustomResourceDefinitionVersionV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceDefinitionVersionV1Beta1( + obj: CustomResourceDefinitionVersionV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'additionalPrinterColumns': obj.additionalPrinterColumns?.map(y => toJson_CustomResourceColumnDefinitionV1Beta1(y)), - 'deprecated': obj.deprecated, - 'deprecationWarning': obj.deprecationWarning, - 'name': obj.name, - 'schema': toJson_CustomResourceValidationV1Beta1(obj.schema), - 'served': obj.served, - 'storage': obj.storage, - 'subresources': toJson_CustomResourceSubresourcesV1Beta1(obj.subresources), + additionalPrinterColumns: obj.additionalPrinterColumns?.map((y) => + toJson_CustomResourceColumnDefinitionV1Beta1(y) + ), + deprecated: obj.deprecated, + deprecationWarning: obj.deprecationWarning, + name: obj.name, + schema: toJson_CustomResourceValidationV1Beta1(obj.schema), + served: obj.served, + storage: obj.storage, + subresources: toJson_CustomResourceSubresourcesV1Beta1(obj.subresources), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30138,22 +33523,28 @@ export interface StatusCause { * @schema io.k8s.apimachinery.pkg.apis.meta.v1.StatusCause#reason */ readonly reason?: string; - } /** * Converts an object of type 'StatusCause' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_StatusCause(obj: StatusCause | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_StatusCause( + obj: StatusCause | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'field': obj.field, - 'message': obj.message, - 'reason': obj.reason, + field: obj.field, + message: obj.message, + reason: obj.reason, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30191,23 +33582,29 @@ export interface ServiceReference { * @schema io.k8s.api.admissionregistration.v1.ServiceReference#port */ readonly port?: number; - } /** * Converts an object of type 'ServiceReference' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ServiceReference(obj: ServiceReference | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ServiceReference( + obj: ServiceReference | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'namespace': obj.namespace, - 'path': obj.path, - 'port': obj.port, + name: obj.name, + namespace: obj.namespace, + path: obj.path, + port: obj.port, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30245,23 +33642,29 @@ export interface ServiceReferenceV1Beta1 { * @schema io.k8s.api.admissionregistration.v1beta1.ServiceReference#port */ readonly port?: number; - } /** * Converts an object of type 'ServiceReferenceV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ServiceReferenceV1Beta1(obj: ServiceReferenceV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ServiceReferenceV1Beta1( + obj: ServiceReferenceV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'namespace': obj.namespace, - 'path': obj.path, - 'port': obj.port, + name: obj.name, + namespace: obj.namespace, + path: obj.path, + port: obj.port, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30284,21 +33687,27 @@ export interface RollingUpdateDaemonSet { * @schema io.k8s.api.apps.v1.RollingUpdateDaemonSet#maxUnavailable */ readonly maxUnavailable?: IntOrString; - } /** * Converts an object of type 'RollingUpdateDaemonSet' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RollingUpdateDaemonSet(obj: RollingUpdateDaemonSet | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RollingUpdateDaemonSet( + obj: RollingUpdateDaemonSet | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'maxSurge': obj.maxSurge?.value, - 'maxUnavailable': obj.maxUnavailable?.value, + maxSurge: obj.maxSurge?.value, + maxUnavailable: obj.maxUnavailable?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30323,21 +33732,27 @@ export interface RollingUpdateDeployment { * @schema io.k8s.api.apps.v1.RollingUpdateDeployment#maxUnavailable */ readonly maxUnavailable?: IntOrString; - } /** * Converts an object of type 'RollingUpdateDeployment' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RollingUpdateDeployment(obj: RollingUpdateDeployment | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RollingUpdateDeployment( + obj: RollingUpdateDeployment | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'maxSurge': obj.maxSurge?.value, - 'maxUnavailable': obj.maxUnavailable?.value, + maxSurge: obj.maxSurge?.value, + maxUnavailable: obj.maxUnavailable?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30353,20 +33768,26 @@ export interface RollingUpdateStatefulSetStrategy { * @schema io.k8s.api.apps.v1.RollingUpdateStatefulSetStrategy#partition */ readonly partition?: number; - } /** * Converts an object of type 'RollingUpdateStatefulSetStrategy' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RollingUpdateStatefulSetStrategy(obj: RollingUpdateStatefulSetStrategy | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RollingUpdateStatefulSetStrategy( + obj: RollingUpdateStatefulSetStrategy | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'partition': obj.partition, + partition: obj.partition, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30403,23 +33824,29 @@ export interface ContainerResourceMetricSourceV2Beta1 { * @schema io.k8s.api.autoscaling.v2beta1.ContainerResourceMetricSource#targetAverageValue */ readonly targetAverageValue?: Quantity; - } /** * Converts an object of type 'ContainerResourceMetricSourceV2Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ContainerResourceMetricSourceV2Beta1(obj: ContainerResourceMetricSourceV2Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ContainerResourceMetricSourceV2Beta1( + obj: ContainerResourceMetricSourceV2Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'container': obj.container, - 'name': obj.name, - 'targetAverageUtilization': obj.targetAverageUtilization, - 'targetAverageValue': obj.targetAverageValue?.value, + container: obj.container, + name: obj.name, + targetAverageUtilization: obj.targetAverageUtilization, + targetAverageValue: obj.targetAverageValue?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30456,23 +33883,29 @@ export interface ExternalMetricSourceV2Beta1 { * @schema io.k8s.api.autoscaling.v2beta1.ExternalMetricSource#targetValue */ readonly targetValue?: Quantity; - } /** * Converts an object of type 'ExternalMetricSourceV2Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ExternalMetricSourceV2Beta1(obj: ExternalMetricSourceV2Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ExternalMetricSourceV2Beta1( + obj: ExternalMetricSourceV2Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metricName': obj.metricName, - 'metricSelector': toJson_LabelSelector(obj.metricSelector), - 'targetAverageValue': obj.targetAverageValue?.value, - 'targetValue': obj.targetValue?.value, + metricName: obj.metricName, + metricSelector: toJson_LabelSelector(obj.metricSelector), + targetAverageValue: obj.targetAverageValue?.value, + targetValue: obj.targetValue?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30516,24 +33949,30 @@ export interface ObjectMetricSourceV2Beta1 { * @schema io.k8s.api.autoscaling.v2beta1.ObjectMetricSource#targetValue */ readonly targetValue: Quantity; - } /** * Converts an object of type 'ObjectMetricSourceV2Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ObjectMetricSourceV2Beta1(obj: ObjectMetricSourceV2Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ObjectMetricSourceV2Beta1( + obj: ObjectMetricSourceV2Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'averageValue': obj.averageValue?.value, - 'metricName': obj.metricName, - 'selector': toJson_LabelSelector(obj.selector), - 'target': toJson_CrossVersionObjectReferenceV2Beta1(obj.target), - 'targetValue': obj.targetValue?.value, + averageValue: obj.averageValue?.value, + metricName: obj.metricName, + selector: toJson_LabelSelector(obj.selector), + target: toJson_CrossVersionObjectReferenceV2Beta1(obj.target), + targetValue: obj.targetValue?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30563,22 +34002,28 @@ export interface PodsMetricSourceV2Beta1 { * @schema io.k8s.api.autoscaling.v2beta1.PodsMetricSource#targetAverageValue */ readonly targetAverageValue: Quantity; - } /** * Converts an object of type 'PodsMetricSourceV2Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodsMetricSourceV2Beta1(obj: PodsMetricSourceV2Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodsMetricSourceV2Beta1( + obj: PodsMetricSourceV2Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metricName': obj.metricName, - 'selector': toJson_LabelSelector(obj.selector), - 'targetAverageValue': obj.targetAverageValue?.value, + metricName: obj.metricName, + selector: toJson_LabelSelector(obj.selector), + targetAverageValue: obj.targetAverageValue?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30608,22 +34053,28 @@ export interface ResourceMetricSourceV2Beta1 { * @schema io.k8s.api.autoscaling.v2beta1.ResourceMetricSource#targetAverageValue */ readonly targetAverageValue?: Quantity; - } /** * Converts an object of type 'ResourceMetricSourceV2Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ResourceMetricSourceV2Beta1(obj: ResourceMetricSourceV2Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ResourceMetricSourceV2Beta1( + obj: ResourceMetricSourceV2Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'targetAverageUtilization': obj.targetAverageUtilization, - 'targetAverageValue': obj.targetAverageValue?.value, + name: obj.name, + targetAverageUtilization: obj.targetAverageUtilization, + targetAverageValue: obj.targetAverageValue?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30653,22 +34104,28 @@ export interface HpaScalingRulesV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.HPAScalingRules#stabilizationWindowSeconds */ readonly stabilizationWindowSeconds?: number; - } /** * Converts an object of type 'HpaScalingRulesV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HpaScalingRulesV2Beta2(obj: HpaScalingRulesV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HpaScalingRulesV2Beta2( + obj: HpaScalingRulesV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'policies': obj.policies?.map(y => toJson_HpaScalingPolicyV2Beta2(y)), - 'selectPolicy': obj.selectPolicy, - 'stabilizationWindowSeconds': obj.stabilizationWindowSeconds, + policies: obj.policies?.map((y) => toJson_HpaScalingPolicyV2Beta2(y)), + selectPolicy: obj.selectPolicy, + stabilizationWindowSeconds: obj.stabilizationWindowSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30698,22 +34155,28 @@ export interface ContainerResourceMetricSourceV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.ContainerResourceMetricSource#target */ readonly target: MetricTargetV2Beta2; - } /** * Converts an object of type 'ContainerResourceMetricSourceV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ContainerResourceMetricSourceV2Beta2(obj: ContainerResourceMetricSourceV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ContainerResourceMetricSourceV2Beta2( + obj: ContainerResourceMetricSourceV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'container': obj.container, - 'name': obj.name, - 'target': toJson_MetricTargetV2Beta2(obj.target), + container: obj.container, + name: obj.name, + target: toJson_MetricTargetV2Beta2(obj.target), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30736,21 +34199,27 @@ export interface ExternalMetricSourceV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.ExternalMetricSource#target */ readonly target: MetricTargetV2Beta2; - } /** * Converts an object of type 'ExternalMetricSourceV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ExternalMetricSourceV2Beta2(obj: ExternalMetricSourceV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ExternalMetricSourceV2Beta2( + obj: ExternalMetricSourceV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metric': toJson_MetricIdentifierV2Beta2(obj.metric), - 'target': toJson_MetricTargetV2Beta2(obj.target), + metric: toJson_MetricIdentifierV2Beta2(obj.metric), + target: toJson_MetricTargetV2Beta2(obj.target), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30778,22 +34247,30 @@ export interface ObjectMetricSourceV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.ObjectMetricSource#target */ readonly target: MetricTargetV2Beta2; - } /** * Converts an object of type 'ObjectMetricSourceV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ObjectMetricSourceV2Beta2(obj: ObjectMetricSourceV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ObjectMetricSourceV2Beta2( + obj: ObjectMetricSourceV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'describedObject': toJson_CrossVersionObjectReferenceV2Beta2(obj.describedObject), - 'metric': toJson_MetricIdentifierV2Beta2(obj.metric), - 'target': toJson_MetricTargetV2Beta2(obj.target), + describedObject: toJson_CrossVersionObjectReferenceV2Beta2( + obj.describedObject + ), + metric: toJson_MetricIdentifierV2Beta2(obj.metric), + target: toJson_MetricTargetV2Beta2(obj.target), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30816,21 +34293,27 @@ export interface PodsMetricSourceV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.PodsMetricSource#target */ readonly target: MetricTargetV2Beta2; - } /** * Converts an object of type 'PodsMetricSourceV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodsMetricSourceV2Beta2(obj: PodsMetricSourceV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodsMetricSourceV2Beta2( + obj: PodsMetricSourceV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metric': toJson_MetricIdentifierV2Beta2(obj.metric), - 'target': toJson_MetricTargetV2Beta2(obj.target), + metric: toJson_MetricIdentifierV2Beta2(obj.metric), + target: toJson_MetricTargetV2Beta2(obj.target), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30853,21 +34336,27 @@ export interface ResourceMetricSourceV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.ResourceMetricSource#target */ readonly target: MetricTargetV2Beta2; - } /** * Converts an object of type 'ResourceMetricSourceV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ResourceMetricSourceV2Beta2(obj: ResourceMetricSourceV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ResourceMetricSourceV2Beta2( + obj: ResourceMetricSourceV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'target': toJson_MetricTargetV2Beta2(obj.target), + name: obj.name, + target: toJson_MetricTargetV2Beta2(obj.target), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30904,23 +34393,29 @@ export interface EnvVarSource { * @schema io.k8s.api.core.v1.EnvVarSource#secretKeyRef */ readonly secretKeyRef?: SecretKeySelector; - } /** * Converts an object of type 'EnvVarSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EnvVarSource(obj: EnvVarSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EnvVarSource( + obj: EnvVarSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'configMapKeyRef': toJson_ConfigMapKeySelector(obj.configMapKeyRef), - 'fieldRef': toJson_ObjectFieldSelector(obj.fieldRef), - 'resourceFieldRef': toJson_ResourceFieldSelector(obj.resourceFieldRef), - 'secretKeyRef': toJson_SecretKeySelector(obj.secretKeyRef), + configMapKeyRef: toJson_ConfigMapKeySelector(obj.configMapKeyRef), + fieldRef: toJson_ObjectFieldSelector(obj.fieldRef), + resourceFieldRef: toJson_ResourceFieldSelector(obj.resourceFieldRef), + secretKeyRef: toJson_SecretKeySelector(obj.secretKeyRef), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30945,21 +34440,27 @@ export interface ConfigMapEnvSource { * @schema io.k8s.api.core.v1.ConfigMapEnvSource#optional */ readonly optional?: boolean; - } /** * Converts an object of type 'ConfigMapEnvSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ConfigMapEnvSource(obj: ConfigMapEnvSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ConfigMapEnvSource( + obj: ConfigMapEnvSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'optional': obj.optional, + name: obj.name, + optional: obj.optional, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -30984,21 +34485,27 @@ export interface SecretEnvSource { * @schema io.k8s.api.core.v1.SecretEnvSource#optional */ readonly optional?: boolean; - } /** * Converts an object of type 'SecretEnvSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SecretEnvSource(obj: SecretEnvSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SecretEnvSource( + obj: SecretEnvSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'optional': obj.optional, + name: obj.name, + optional: obj.optional, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31028,22 +34535,28 @@ export interface Handler { * @schema io.k8s.api.core.v1.Handler#tcpSocket */ readonly tcpSocket?: TcpSocketAction; - } /** * Converts an object of type 'Handler' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Handler(obj: Handler | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Handler( + obj: Handler | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'exec': toJson_ExecAction(obj.exec), - 'httpGet': toJson_HttpGetAction(obj.httpGet), - 'tcpSocket': toJson_TcpSocketAction(obj.tcpSocket), + exec: toJson_ExecAction(obj.exec), + httpGet: toJson_HttpGetAction(obj.httpGet), + tcpSocket: toJson_TcpSocketAction(obj.tcpSocket), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31059,20 +34572,26 @@ export interface ExecAction { * @schema io.k8s.api.core.v1.ExecAction#command */ readonly command?: string[]; - } /** * Converts an object of type 'ExecAction' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ExecAction(obj: ExecAction | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ExecAction( + obj: ExecAction | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'command': obj.command?.map(y => y), + command: obj.command?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31117,24 +34636,30 @@ export interface HttpGetAction { * @schema io.k8s.api.core.v1.HTTPGetAction#scheme */ readonly scheme?: string; - } /** * Converts an object of type 'HttpGetAction' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HttpGetAction(obj: HttpGetAction | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HttpGetAction( + obj: HttpGetAction | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'host': obj.host, - 'httpHeaders': obj.httpHeaders?.map(y => toJson_HttpHeader(y)), - 'path': obj.path, - 'port': obj.port?.value, - 'scheme': obj.scheme, + host: obj.host, + httpHeaders: obj.httpHeaders?.map((y) => toJson_HttpHeader(y)), + path: obj.path, + port: obj.port?.value, + scheme: obj.scheme, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31157,21 +34682,27 @@ export interface TcpSocketAction { * @schema io.k8s.api.core.v1.TCPSocketAction#port */ readonly port: IntOrString; - } /** * Converts an object of type 'TcpSocketAction' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_TcpSocketAction(obj: TcpSocketAction | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_TcpSocketAction( + obj: TcpSocketAction | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'host': obj.host, - 'port': obj.port?.value, + host: obj.host, + port: obj.port?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31194,21 +34725,27 @@ export interface Capabilities { * @schema io.k8s.api.core.v1.Capabilities#drop */ readonly drop?: string[]; - } /** * Converts an object of type 'Capabilities' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Capabilities(obj: Capabilities | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Capabilities( + obj: Capabilities | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'add': obj.add?.map(y => y), - 'drop': obj.drop?.map(y => y), + add: obj.add?.map((y) => y), + drop: obj.drop?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31245,23 +34782,29 @@ export interface SeLinuxOptions { * @schema io.k8s.api.core.v1.SELinuxOptions#user */ readonly user?: string; - } /** * Converts an object of type 'SeLinuxOptions' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SeLinuxOptions(obj: SeLinuxOptions | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SeLinuxOptions( + obj: SeLinuxOptions | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'level': obj.level, - 'role': obj.role, - 'type': obj.type, - 'user': obj.user, + level: obj.level, + role: obj.role, + type: obj.type, + user: obj.user, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31286,21 +34829,27 @@ export interface SeccompProfile { * @schema io.k8s.api.core.v1.SeccompProfile#type */ readonly type: string; - } /** * Converts an object of type 'SeccompProfile' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SeccompProfile(obj: SeccompProfile | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SeccompProfile( + obj: SeccompProfile | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'localhostProfile': obj.localhostProfile, - 'type': obj.type, + localhostProfile: obj.localhostProfile, + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31331,22 +34880,28 @@ export interface WindowsSecurityContextOptions { * @schema io.k8s.api.core.v1.WindowsSecurityContextOptions#runAsUserName */ readonly runAsUserName?: string; - } /** * Converts an object of type 'WindowsSecurityContextOptions' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_WindowsSecurityContextOptions(obj: WindowsSecurityContextOptions | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_WindowsSecurityContextOptions( + obj: WindowsSecurityContextOptions | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'gmsaCredentialSpec': obj.gmsaCredentialSpec, - 'gmsaCredentialSpecName': obj.gmsaCredentialSpecName, - 'runAsUserName': obj.runAsUserName, + gmsaCredentialSpec: obj.gmsaCredentialSpec, + gmsaCredentialSpecName: obj.gmsaCredentialSpecName, + runAsUserName: obj.runAsUserName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31390,24 +34945,30 @@ export interface ConfigMapNodeConfigSource { * @schema io.k8s.api.core.v1.ConfigMapNodeConfigSource#uid */ readonly uid?: string; - } /** * Converts an object of type 'ConfigMapNodeConfigSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ConfigMapNodeConfigSource(obj: ConfigMapNodeConfigSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ConfigMapNodeConfigSource( + obj: ConfigMapNodeConfigSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'kubeletConfigKey': obj.kubeletConfigKey, - 'name': obj.name, - 'namespace': obj.namespace, - 'resourceVersion': obj.resourceVersion, - 'uid': obj.uid, + kubeletConfigKey: obj.kubeletConfigKey, + name: obj.name, + namespace: obj.namespace, + resourceVersion: obj.resourceVersion, + uid: obj.uid, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31430,21 +34991,27 @@ export interface SecretReference { * @schema io.k8s.api.core.v1.SecretReference#namespace */ readonly namespace?: string; - } /** * Converts an object of type 'SecretReference' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SecretReference(obj: SecretReference | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SecretReference( + obj: SecretReference | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'namespace': obj.namespace, + name: obj.name, + namespace: obj.namespace, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31460,20 +35027,28 @@ export interface NodeSelector { * @schema io.k8s.api.core.v1.NodeSelector#nodeSelectorTerms */ readonly nodeSelectorTerms: NodeSelectorTerm[]; - } /** * Converts an object of type 'NodeSelector' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NodeSelector(obj: NodeSelector | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NodeSelector( + obj: NodeSelector | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nodeSelectorTerms': obj.nodeSelectorTerms?.map(y => toJson_NodeSelectorTerm(y)), + nodeSelectorTerms: obj.nodeSelectorTerms?.map((y) => + toJson_NodeSelectorTerm(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31496,21 +35071,32 @@ export interface NodeAffinity { * @schema io.k8s.api.core.v1.NodeAffinity#requiredDuringSchedulingIgnoredDuringExecution */ readonly requiredDuringSchedulingIgnoredDuringExecution?: NodeSelector; - } /** * Converts an object of type 'NodeAffinity' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NodeAffinity(obj: NodeAffinity | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NodeAffinity( + obj: NodeAffinity | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'preferredDuringSchedulingIgnoredDuringExecution': obj.preferredDuringSchedulingIgnoredDuringExecution?.map(y => toJson_PreferredSchedulingTerm(y)), - 'requiredDuringSchedulingIgnoredDuringExecution': toJson_NodeSelector(obj.requiredDuringSchedulingIgnoredDuringExecution), + preferredDuringSchedulingIgnoredDuringExecution: + obj.preferredDuringSchedulingIgnoredDuringExecution?.map((y) => + toJson_PreferredSchedulingTerm(y) + ), + requiredDuringSchedulingIgnoredDuringExecution: toJson_NodeSelector( + obj.requiredDuringSchedulingIgnoredDuringExecution + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31533,21 +35119,33 @@ export interface PodAffinity { * @schema io.k8s.api.core.v1.PodAffinity#requiredDuringSchedulingIgnoredDuringExecution */ readonly requiredDuringSchedulingIgnoredDuringExecution?: PodAffinityTerm[]; - } /** * Converts an object of type 'PodAffinity' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodAffinity(obj: PodAffinity | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodAffinity( + obj: PodAffinity | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'preferredDuringSchedulingIgnoredDuringExecution': obj.preferredDuringSchedulingIgnoredDuringExecution?.map(y => toJson_WeightedPodAffinityTerm(y)), - 'requiredDuringSchedulingIgnoredDuringExecution': obj.requiredDuringSchedulingIgnoredDuringExecution?.map(y => toJson_PodAffinityTerm(y)), + preferredDuringSchedulingIgnoredDuringExecution: + obj.preferredDuringSchedulingIgnoredDuringExecution?.map((y) => + toJson_WeightedPodAffinityTerm(y) + ), + requiredDuringSchedulingIgnoredDuringExecution: + obj.requiredDuringSchedulingIgnoredDuringExecution?.map((y) => + toJson_PodAffinityTerm(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31570,21 +35168,33 @@ export interface PodAntiAffinity { * @schema io.k8s.api.core.v1.PodAntiAffinity#requiredDuringSchedulingIgnoredDuringExecution */ readonly requiredDuringSchedulingIgnoredDuringExecution?: PodAffinityTerm[]; - } /** * Converts an object of type 'PodAntiAffinity' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodAntiAffinity(obj: PodAntiAffinity | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodAntiAffinity( + obj: PodAntiAffinity | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'preferredDuringSchedulingIgnoredDuringExecution': obj.preferredDuringSchedulingIgnoredDuringExecution?.map(y => toJson_WeightedPodAffinityTerm(y)), - 'requiredDuringSchedulingIgnoredDuringExecution': obj.requiredDuringSchedulingIgnoredDuringExecution?.map(y => toJson_PodAffinityTerm(y)), + preferredDuringSchedulingIgnoredDuringExecution: + obj.preferredDuringSchedulingIgnoredDuringExecution?.map((y) => + toJson_WeightedPodAffinityTerm(y) + ), + requiredDuringSchedulingIgnoredDuringExecution: + obj.requiredDuringSchedulingIgnoredDuringExecution?.map((y) => + toJson_PodAffinityTerm(y) + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31605,21 +35215,27 @@ export interface PodDnsConfigOption { * @schema io.k8s.api.core.v1.PodDNSConfigOption#value */ readonly value?: string; - } /** * Converts an object of type 'PodDnsConfigOption' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodDnsConfigOption(obj: PodDnsConfigOption | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodDnsConfigOption( + obj: PodDnsConfigOption | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'value': obj.value, + name: obj.name, + value: obj.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31642,21 +35258,27 @@ export interface Sysctl { * @schema io.k8s.api.core.v1.Sysctl#value */ readonly value: string; - } /** * Converts an object of type 'Sysctl' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_Sysctl(obj: Sysctl | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_Sysctl( + obj: Sysctl | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'value': obj.value, + name: obj.name, + value: obj.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31687,22 +35309,28 @@ export interface AzureFileVolumeSource { * @schema io.k8s.api.core.v1.AzureFileVolumeSource#shareName */ readonly shareName: string; - } /** * Converts an object of type 'AzureFileVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_AzureFileVolumeSource(obj: AzureFileVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_AzureFileVolumeSource( + obj: AzureFileVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'readOnly': obj.readOnly, - 'secretName': obj.secretName, - 'shareName': obj.shareName, + readOnly: obj.readOnly, + secretName: obj.secretName, + shareName: obj.shareName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31754,25 +35382,31 @@ export interface CephFsVolumeSource { * @schema io.k8s.api.core.v1.CephFSVolumeSource#user */ readonly user?: string; - } /** * Converts an object of type 'CephFsVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CephFsVolumeSource(obj: CephFsVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CephFsVolumeSource( + obj: CephFsVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'monitors': obj.monitors?.map(y => y), - 'path': obj.path, - 'readOnly': obj.readOnly, - 'secretFile': obj.secretFile, - 'secretRef': toJson_LocalObjectReference(obj.secretRef), - 'user': obj.user, + monitors: obj.monitors?.map((y) => y), + path: obj.path, + readOnly: obj.readOnly, + secretFile: obj.secretFile, + secretRef: toJson_LocalObjectReference(obj.secretRef), + user: obj.user, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31810,23 +35444,29 @@ export interface CinderVolumeSource { * @schema io.k8s.api.core.v1.CinderVolumeSource#volumeID */ readonly volumeId: string; - } /** * Converts an object of type 'CinderVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CinderVolumeSource(obj: CinderVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CinderVolumeSource( + obj: CinderVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'readOnly': obj.readOnly, - 'secretRef': toJson_LocalObjectReference(obj.secretRef), - 'volumeID': obj.volumeId, + fsType: obj.fsType, + readOnly: obj.readOnly, + secretRef: toJson_LocalObjectReference(obj.secretRef), + volumeID: obj.volumeId, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31866,23 +35506,29 @@ export interface ConfigMapVolumeSource { * @schema io.k8s.api.core.v1.ConfigMapVolumeSource#optional */ readonly optional?: boolean; - } /** * Converts an object of type 'ConfigMapVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ConfigMapVolumeSource(obj: ConfigMapVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ConfigMapVolumeSource( + obj: ConfigMapVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'defaultMode': obj.defaultMode, - 'items': obj.items?.map(y => toJson_KeyToPath(y)), - 'name': obj.name, - 'optional': obj.optional, + defaultMode: obj.defaultMode, + items: obj.items?.map((y) => toJson_KeyToPath(y)), + name: obj.name, + optional: obj.optional, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31927,24 +35573,36 @@ export interface CsiVolumeSource { * @schema io.k8s.api.core.v1.CSIVolumeSource#volumeAttributes */ readonly volumeAttributes?: { [key: string]: string }; - } /** * Converts an object of type 'CsiVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CsiVolumeSource(obj: CsiVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CsiVolumeSource( + obj: CsiVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'driver': obj.driver, - 'fsType': obj.fsType, - 'nodePublishSecretRef': toJson_LocalObjectReference(obj.nodePublishSecretRef), - 'readOnly': obj.readOnly, - 'volumeAttributes': ((obj.volumeAttributes) === undefined) ? undefined : (Object.entries(obj.volumeAttributes).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), + driver: obj.driver, + fsType: obj.fsType, + nodePublishSecretRef: toJson_LocalObjectReference(obj.nodePublishSecretRef), + readOnly: obj.readOnly, + volumeAttributes: + obj.volumeAttributes === undefined + ? undefined + : Object.entries(obj.volumeAttributes).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -31968,21 +35626,27 @@ export interface DownwardApiVolumeSource { * @schema io.k8s.api.core.v1.DownwardAPIVolumeSource#items */ readonly items?: DownwardApiVolumeFile[]; - } /** * Converts an object of type 'DownwardApiVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_DownwardApiVolumeSource(obj: DownwardApiVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_DownwardApiVolumeSource( + obj: DownwardApiVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'defaultMode': obj.defaultMode, - 'items': obj.items?.map(y => toJson_DownwardApiVolumeFile(y)), + defaultMode: obj.defaultMode, + items: obj.items?.map((y) => toJson_DownwardApiVolumeFile(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32005,21 +35669,27 @@ export interface EmptyDirVolumeSource { * @schema io.k8s.api.core.v1.EmptyDirVolumeSource#sizeLimit */ readonly sizeLimit?: Quantity; - } /** * Converts an object of type 'EmptyDirVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EmptyDirVolumeSource(obj: EmptyDirVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EmptyDirVolumeSource( + obj: EmptyDirVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'medium': obj.medium, - 'sizeLimit': obj.sizeLimit?.value, + medium: obj.medium, + sizeLimit: obj.sizeLimit?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32041,20 +35711,28 @@ export interface EphemeralVolumeSource { * @schema io.k8s.api.core.v1.EphemeralVolumeSource#volumeClaimTemplate */ readonly volumeClaimTemplate?: PersistentVolumeClaimTemplate; - } /** * Converts an object of type 'EphemeralVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_EphemeralVolumeSource(obj: EphemeralVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_EphemeralVolumeSource( + obj: EphemeralVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'volumeClaimTemplate': toJson_PersistentVolumeClaimTemplate(obj.volumeClaimTemplate), + volumeClaimTemplate: toJson_PersistentVolumeClaimTemplate( + obj.volumeClaimTemplate + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32099,24 +35777,36 @@ export interface FlexVolumeSource { * @schema io.k8s.api.core.v1.FlexVolumeSource#secretRef */ readonly secretRef?: LocalObjectReference; - } /** * Converts an object of type 'FlexVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_FlexVolumeSource(obj: FlexVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_FlexVolumeSource( + obj: FlexVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'driver': obj.driver, - 'fsType': obj.fsType, - 'options': ((obj.options) === undefined) ? undefined : (Object.entries(obj.options).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'readOnly': obj.readOnly, - 'secretRef': toJson_LocalObjectReference(obj.secretRef), + driver: obj.driver, + fsType: obj.fsType, + options: + obj.options === undefined + ? undefined + : Object.entries(obj.options).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + readOnly: obj.readOnly, + secretRef: toJson_LocalObjectReference(obj.secretRef), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32148,22 +35838,28 @@ export interface GitRepoVolumeSource { * @schema io.k8s.api.core.v1.GitRepoVolumeSource#revision */ readonly revision?: string; - } /** * Converts an object of type 'GitRepoVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_GitRepoVolumeSource(obj: GitRepoVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_GitRepoVolumeSource( + obj: GitRepoVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'directory': obj.directory, - 'repository': obj.repository, - 'revision': obj.revision, + directory: obj.directory, + repository: obj.repository, + revision: obj.revision, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32194,22 +35890,28 @@ export interface GlusterfsVolumeSource { * @schema io.k8s.api.core.v1.GlusterfsVolumeSource#readOnly */ readonly readOnly?: boolean; - } /** * Converts an object of type 'GlusterfsVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_GlusterfsVolumeSource(obj: GlusterfsVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_GlusterfsVolumeSource( + obj: GlusterfsVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'endpoints': obj.endpoints, - 'path': obj.path, - 'readOnly': obj.readOnly, + endpoints: obj.endpoints, + path: obj.path, + readOnly: obj.readOnly, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32297,30 +35999,36 @@ export interface IscsiVolumeSource { * @schema io.k8s.api.core.v1.ISCSIVolumeSource#targetPortal */ readonly targetPortal: string; - } /** * Converts an object of type 'IscsiVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IscsiVolumeSource(obj: IscsiVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IscsiVolumeSource( + obj: IscsiVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'chapAuthDiscovery': obj.chapAuthDiscovery, - 'chapAuthSession': obj.chapAuthSession, - 'fsType': obj.fsType, - 'initiatorName': obj.initiatorName, - 'iqn': obj.iqn, - 'iscsiInterface': obj.iscsiInterface, - 'lun': obj.lun, - 'portals': obj.portals?.map(y => y), - 'readOnly': obj.readOnly, - 'secretRef': toJson_LocalObjectReference(obj.secretRef), - 'targetPortal': obj.targetPortal, + chapAuthDiscovery: obj.chapAuthDiscovery, + chapAuthSession: obj.chapAuthSession, + fsType: obj.fsType, + initiatorName: obj.initiatorName, + iqn: obj.iqn, + iscsiInterface: obj.iscsiInterface, + lun: obj.lun, + portals: obj.portals?.map((y) => y), + readOnly: obj.readOnly, + secretRef: toJson_LocalObjectReference(obj.secretRef), + targetPortal: obj.targetPortal, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32343,21 +36051,27 @@ export interface PersistentVolumeClaimVolumeSource { * @schema io.k8s.api.core.v1.PersistentVolumeClaimVolumeSource#readOnly */ readonly readOnly?: boolean; - } /** * Converts an object of type 'PersistentVolumeClaimVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PersistentVolumeClaimVolumeSource(obj: PersistentVolumeClaimVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PersistentVolumeClaimVolumeSource( + obj: PersistentVolumeClaimVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'claimName': obj.claimName, - 'readOnly': obj.readOnly, + claimName: obj.claimName, + readOnly: obj.readOnly, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32380,21 +36094,27 @@ export interface ProjectedVolumeSource { * @schema io.k8s.api.core.v1.ProjectedVolumeSource#sources */ readonly sources?: VolumeProjection[]; - } /** * Converts an object of type 'ProjectedVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ProjectedVolumeSource(obj: ProjectedVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ProjectedVolumeSource( + obj: ProjectedVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'defaultMode': obj.defaultMode, - 'sources': obj.sources?.map(y => toJson_VolumeProjection(y)), + defaultMode: obj.defaultMode, + sources: obj.sources?.map((y) => toJson_VolumeProjection(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32464,27 +36184,33 @@ export interface RbdVolumeSource { * @schema io.k8s.api.core.v1.RBDVolumeSource#user */ readonly user?: string; - } /** * Converts an object of type 'RbdVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_RbdVolumeSource(obj: RbdVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_RbdVolumeSource( + obj: RbdVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'image': obj.image, - 'keyring': obj.keyring, - 'monitors': obj.monitors?.map(y => y), - 'pool': obj.pool, - 'readOnly': obj.readOnly, - 'secretRef': toJson_LocalObjectReference(obj.secretRef), - 'user': obj.user, + fsType: obj.fsType, + image: obj.image, + keyring: obj.keyring, + monitors: obj.monitors?.map((y) => y), + pool: obj.pool, + readOnly: obj.readOnly, + secretRef: toJson_LocalObjectReference(obj.secretRef), + user: obj.user, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32566,29 +36292,35 @@ export interface ScaleIoVolumeSource { * @schema io.k8s.api.core.v1.ScaleIOVolumeSource#volumeName */ readonly volumeName?: string; - } /** * Converts an object of type 'ScaleIoVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ScaleIoVolumeSource(obj: ScaleIoVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ScaleIoVolumeSource( + obj: ScaleIoVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'gateway': obj.gateway, - 'protectionDomain': obj.protectionDomain, - 'readOnly': obj.readOnly, - 'secretRef': toJson_LocalObjectReference(obj.secretRef), - 'sslEnabled': obj.sslEnabled, - 'storageMode': obj.storageMode, - 'storagePool': obj.storagePool, - 'system': obj.system, - 'volumeName': obj.volumeName, + fsType: obj.fsType, + gateway: obj.gateway, + protectionDomain: obj.protectionDomain, + readOnly: obj.readOnly, + secretRef: toJson_LocalObjectReference(obj.secretRef), + sslEnabled: obj.sslEnabled, + storageMode: obj.storageMode, + storagePool: obj.storagePool, + system: obj.system, + volumeName: obj.volumeName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32628,23 +36360,29 @@ export interface SecretVolumeSource { * @schema io.k8s.api.core.v1.SecretVolumeSource#secretName */ readonly secretName?: string; - } /** * Converts an object of type 'SecretVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SecretVolumeSource(obj: SecretVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SecretVolumeSource( + obj: SecretVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'defaultMode': obj.defaultMode, - 'items': obj.items?.map(y => toJson_KeyToPath(y)), - 'optional': obj.optional, - 'secretName': obj.secretName, + defaultMode: obj.defaultMode, + items: obj.items?.map((y) => toJson_KeyToPath(y)), + optional: obj.optional, + secretName: obj.secretName, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32689,24 +36427,30 @@ export interface StorageOsVolumeSource { * @schema io.k8s.api.core.v1.StorageOSVolumeSource#volumeNamespace */ readonly volumeNamespace?: string; - } /** * Converts an object of type 'StorageOsVolumeSource' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_StorageOsVolumeSource(obj: StorageOsVolumeSource | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_StorageOsVolumeSource( + obj: StorageOsVolumeSource | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fsType': obj.fsType, - 'readOnly': obj.readOnly, - 'secretRef': toJson_LocalObjectReference(obj.secretRef), - 'volumeName': obj.volumeName, - 'volumeNamespace': obj.volumeNamespace, + fsType: obj.fsType, + readOnly: obj.readOnly, + secretRef: toJson_LocalObjectReference(obj.secretRef), + volumeName: obj.volumeName, + volumeNamespace: obj.volumeNamespace, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32736,22 +36480,28 @@ export interface ScopedResourceSelectorRequirement { * @schema io.k8s.api.core.v1.ScopedResourceSelectorRequirement#values */ readonly values?: string[]; - } /** * Converts an object of type 'ScopedResourceSelectorRequirement' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ScopedResourceSelectorRequirement(obj: ScopedResourceSelectorRequirement | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ScopedResourceSelectorRequirement( + obj: ScopedResourceSelectorRequirement | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'operator': obj.operator, - 'scopeName': obj.scopeName, - 'values': obj.values?.map(y => y), + operator: obj.operator, + scopeName: obj.scopeName, + values: obj.values?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32767,20 +36517,26 @@ export interface ClientIpConfig { * @schema io.k8s.api.core.v1.ClientIPConfig#timeoutSeconds */ readonly timeoutSeconds?: number; - } /** * Converts an object of type 'ClientIpConfig' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ClientIpConfig(obj: ClientIpConfig | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ClientIpConfig( + obj: ClientIpConfig | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'timeoutSeconds': obj.timeoutSeconds, + timeoutSeconds: obj.timeoutSeconds, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32796,20 +36552,26 @@ export interface ForZone { * @schema io.k8s.api.discovery.v1.ForZone#name */ readonly name: string; - } /** * Converts an object of type 'ForZone' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ForZone(obj: ForZone | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ForZone( + obj: ForZone | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32825,20 +36587,26 @@ export interface ForZoneV1Beta1 { * @schema io.k8s.api.discovery.v1beta1.ForZone#name */ readonly name: string; - } /** * Converts an object of type 'ForZoneV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ForZoneV1Beta1(obj: ForZoneV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ForZoneV1Beta1( + obj: ForZoneV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, + name: obj.name, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32854,20 +36622,26 @@ export interface HttpIngressRuleValueV1Beta1 { * @schema io.k8s.api.networking.v1beta1.HTTPIngressRuleValue#paths */ readonly paths: HttpIngressPathV1Beta1[]; - } /** * Converts an object of type 'HttpIngressRuleValueV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HttpIngressRuleValueV1Beta1(obj: HttpIngressRuleValueV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HttpIngressRuleValueV1Beta1( + obj: HttpIngressRuleValueV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'paths': obj.paths?.map(y => toJson_HttpIngressPathV1Beta1(y)), + paths: obj.paths?.map((y) => toJson_HttpIngressPathV1Beta1(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32896,21 +36670,27 @@ export interface NonResourcePolicyRuleV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.NonResourcePolicyRule#verbs */ readonly verbs: string[]; - } /** * Converts an object of type 'NonResourcePolicyRuleV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NonResourcePolicyRuleV1Beta1(obj: NonResourcePolicyRuleV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NonResourcePolicyRuleV1Beta1( + obj: NonResourcePolicyRuleV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'nonResourceURLs': obj.nonResourceUrLs?.map(y => y), - 'verbs': obj.verbs?.map(y => y), + nonResourceURLs: obj.nonResourceUrLs?.map((y) => y), + verbs: obj.verbs?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32954,24 +36734,30 @@ export interface ResourcePolicyRuleV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.ResourcePolicyRule#verbs */ readonly verbs: string[]; - } /** * Converts an object of type 'ResourcePolicyRuleV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ResourcePolicyRuleV1Beta1(obj: ResourcePolicyRuleV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ResourcePolicyRuleV1Beta1( + obj: ResourcePolicyRuleV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiGroups': obj.apiGroups?.map(y => y), - 'clusterScope': obj.clusterScope, - 'namespaces': obj.namespaces?.map(y => y), - 'resources': obj.resources?.map(y => y), - 'verbs': obj.verbs?.map(y => y), + apiGroups: obj.apiGroups?.map((y) => y), + clusterScope: obj.clusterScope, + namespaces: obj.namespaces?.map((y) => y), + resources: obj.resources?.map((y) => y), + verbs: obj.verbs?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -32994,21 +36780,27 @@ export interface LimitResponseV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.LimitResponse#type */ readonly type: string; - } /** * Converts an object of type 'LimitResponseV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_LimitResponseV1Beta1(obj: LimitResponseV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_LimitResponseV1Beta1( + obj: LimitResponseV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'queuing': toJson_QueuingConfigurationV1Beta1(obj.queuing), - 'type': obj.type, + queuing: toJson_QueuingConfigurationV1Beta1(obj.queuing), + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33031,21 +36823,27 @@ export interface IngressServiceBackend { * @schema io.k8s.api.networking.v1.IngressServiceBackend#port */ readonly port?: ServiceBackendPort; - } /** * Converts an object of type 'IngressServiceBackend' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IngressServiceBackend(obj: IngressServiceBackend | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IngressServiceBackend( + obj: IngressServiceBackend | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'port': toJson_ServiceBackendPort(obj.port), + name: obj.name, + port: toJson_ServiceBackendPort(obj.port), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33061,20 +36859,26 @@ export interface HttpIngressRuleValue { * @schema io.k8s.api.networking.v1.HTTPIngressRuleValue#paths */ readonly paths: HttpIngressPath[]; - } /** * Converts an object of type 'HttpIngressRuleValue' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HttpIngressRuleValue(obj: HttpIngressRuleValue | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HttpIngressRuleValue( + obj: HttpIngressRuleValue | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'paths': obj.paths?.map(y => toJson_HttpIngressPath(y)), + paths: obj.paths?.map((y) => toJson_HttpIngressPath(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33104,22 +36908,28 @@ export interface NetworkPolicyPort { * @schema io.k8s.api.networking.v1.NetworkPolicyPort#protocol */ readonly protocol?: string; - } /** * Converts an object of type 'NetworkPolicyPort' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NetworkPolicyPort(obj: NetworkPolicyPort | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NetworkPolicyPort( + obj: NetworkPolicyPort | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'endPort': obj.endPort, - 'port': obj.port?.value, - 'protocol': obj.protocol, + endPort: obj.endPort, + port: obj.port?.value, + protocol: obj.protocol, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33153,22 +36963,28 @@ export interface NetworkPolicyPeer { * @schema io.k8s.api.networking.v1.NetworkPolicyPeer#podSelector */ readonly podSelector?: LabelSelector; - } /** * Converts an object of type 'NetworkPolicyPeer' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NetworkPolicyPeer(obj: NetworkPolicyPeer | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NetworkPolicyPeer( + obj: NetworkPolicyPeer | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'ipBlock': toJson_IpBlock(obj.ipBlock), - 'namespaceSelector': toJson_LabelSelector(obj.namespaceSelector), - 'podSelector': toJson_LabelSelector(obj.podSelector), + ipBlock: toJson_IpBlock(obj.ipBlock), + namespaceSelector: toJson_LabelSelector(obj.namespaceSelector), + podSelector: toJson_LabelSelector(obj.podSelector), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33191,21 +37007,27 @@ export interface IdRangeV1Beta1 { * @schema io.k8s.api.policy.v1beta1.IDRange#min */ readonly min: number; - } /** * Converts an object of type 'IdRangeV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IdRangeV1Beta1(obj: IdRangeV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IdRangeV1Beta1( + obj: IdRangeV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'max': obj.max, - 'min': obj.min, + max: obj.max, + min: obj.min, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33221,20 +37043,26 @@ export interface VolumeNodeResources { * @schema io.k8s.api.storage.v1.VolumeNodeResources#count */ readonly count?: number; - } /** * Converts an object of type 'VolumeNodeResources' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeNodeResources(obj: VolumeNodeResources | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeNodeResources( + obj: VolumeNodeResources | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'count': obj.count, + count: obj.count, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33250,20 +37078,26 @@ export interface VolumeNodeResourcesV1Beta1 { * @schema io.k8s.api.storage.v1beta1.VolumeNodeResources#count */ readonly count?: number; - } /** * Converts an object of type 'VolumeNodeResourcesV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeNodeResourcesV1Beta1(obj: VolumeNodeResourcesV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeNodeResourcesV1Beta1( + obj: VolumeNodeResourcesV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'count': obj.count, + count: obj.count, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33286,21 +37120,27 @@ export interface WebhookConversion { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.WebhookConversion#conversionReviewVersions */ readonly conversionReviewVersions: string[]; - } /** * Converts an object of type 'WebhookConversion' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_WebhookConversion(obj: WebhookConversion | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_WebhookConversion( + obj: WebhookConversion | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'clientConfig': toJson_WebhookClientConfig(obj.clientConfig), - 'conversionReviewVersions': obj.conversionReviewVersions?.map(y => y), + clientConfig: toJson_WebhookClientConfig(obj.clientConfig), + conversionReviewVersions: obj.conversionReviewVersions?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33351,25 +37191,31 @@ export interface CustomResourceColumnDefinition { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceColumnDefinition#type */ readonly type: string; - } /** * Converts an object of type 'CustomResourceColumnDefinition' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceColumnDefinition(obj: CustomResourceColumnDefinition | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceColumnDefinition( + obj: CustomResourceColumnDefinition | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'description': obj.description, - 'format': obj.format, - 'jsonPath': obj.jsonPath, - 'name': obj.name, - 'priority': obj.priority, - 'type': obj.type, + description: obj.description, + format: obj.format, + jsonPath: obj.jsonPath, + name: obj.name, + priority: obj.priority, + type: obj.type, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33385,20 +37231,26 @@ export interface CustomResourceValidation { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceValidation#openAPIV3Schema */ readonly openApiv3Schema?: JsonSchemaProps; - } /** * Converts an object of type 'CustomResourceValidation' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceValidation(obj: CustomResourceValidation | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceValidation( + obj: CustomResourceValidation | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'openAPIV3Schema': toJson_JsonSchemaProps(obj.openApiv3Schema), + openAPIV3Schema: toJson_JsonSchemaProps(obj.openApiv3Schema), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33421,21 +37273,27 @@ export interface CustomResourceSubresources { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceSubresources#status */ readonly status?: any; - } /** * Converts an object of type 'CustomResourceSubresources' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceSubresources(obj: CustomResourceSubresources | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceSubresources( + obj: CustomResourceSubresources | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'scale': toJson_CustomResourceSubresourceScale(obj.scale), - 'status': obj.status, + scale: toJson_CustomResourceSubresourceScale(obj.scale), + status: obj.status, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33465,22 +37323,28 @@ export interface CustomResourceSubresourceScaleV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.CustomResourceSubresourceScale#statusReplicasPath */ readonly statusReplicasPath: string; - } /** * Converts an object of type 'CustomResourceSubresourceScaleV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceSubresourceScaleV1Beta1(obj: CustomResourceSubresourceScaleV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceSubresourceScaleV1Beta1( + obj: CustomResourceSubresourceScaleV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'labelSelectorPath': obj.labelSelectorPath, - 'specReplicasPath': obj.specReplicasPath, - 'statusReplicasPath': obj.statusReplicasPath, + labelSelectorPath: obj.labelSelectorPath, + specReplicasPath: obj.specReplicasPath, + statusReplicasPath: obj.statusReplicasPath, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33756,62 +37620,102 @@ export interface JsonSchemaPropsV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.JSONSchemaProps#x-kubernetes-preserve-unknown-fields */ readonly xKubernetesPreserveUnknownFields?: boolean; - } /** * Converts an object of type 'JsonSchemaPropsV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_JsonSchemaPropsV1Beta1(obj: JsonSchemaPropsV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } - const result = { - '$ref': obj.ref, - '$schema': obj.schema, - 'additionalItems': obj.additionalItems, - 'additionalProperties': obj.additionalProperties, - 'allOf': obj.allOf?.map(y => toJson_JsonSchemaPropsV1Beta1(y)), - 'anyOf': obj.anyOf?.map(y => toJson_JsonSchemaPropsV1Beta1(y)), - 'default': obj.default, - 'definitions': ((obj.definitions) === undefined) ? undefined : (Object.entries(obj.definitions).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: toJson_JsonSchemaPropsV1Beta1(i[1]) }), {})), - 'dependencies': ((obj.dependencies) === undefined) ? undefined : (Object.entries(obj.dependencies).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'description': obj.description, - 'enum': obj.enum?.map(y => y), - 'example': obj.example, - 'exclusiveMaximum': obj.exclusiveMaximum, - 'exclusiveMinimum': obj.exclusiveMinimum, - 'externalDocs': toJson_ExternalDocumentationV1Beta1(obj.externalDocs), - 'format': obj.format, - 'id': obj.id, - 'items': obj.items, - 'maxItems': obj.maxItems, - 'maxLength': obj.maxLength, - 'maxProperties': obj.maxProperties, - 'maximum': obj.maximum, - 'minItems': obj.minItems, - 'minLength': obj.minLength, - 'minProperties': obj.minProperties, - 'minimum': obj.minimum, - 'multipleOf': obj.multipleOf, - 'not': toJson_JsonSchemaPropsV1Beta1(obj.not), - 'nullable': obj.nullable, - 'oneOf': obj.oneOf?.map(y => toJson_JsonSchemaPropsV1Beta1(y)), - 'pattern': obj.pattern, - 'patternProperties': ((obj.patternProperties) === undefined) ? undefined : (Object.entries(obj.patternProperties).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: toJson_JsonSchemaPropsV1Beta1(i[1]) }), {})), - 'properties': ((obj.properties) === undefined) ? undefined : (Object.entries(obj.properties).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: toJson_JsonSchemaPropsV1Beta1(i[1]) }), {})), - 'required': obj.required?.map(y => y), - 'title': obj.title, - 'type': obj.type, - 'uniqueItems': obj.uniqueItems, - 'x-kubernetes-embedded-resource': obj.xKubernetesEmbeddedResource, - 'x-kubernetes-int-or-string': obj.xKubernetesIntOrString, - 'x-kubernetes-list-map-keys': obj.xKubernetesListMapKeys?.map(y => y), - 'x-kubernetes-list-type': obj.xKubernetesListType, - 'x-kubernetes-map-type': obj.xKubernetesMapType, - 'x-kubernetes-preserve-unknown-fields': obj.xKubernetesPreserveUnknownFields, - }; - // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); +export function toJson_JsonSchemaPropsV1Beta1( + obj: JsonSchemaPropsV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } + const result = { + $ref: obj.ref, + $schema: obj.schema, + additionalItems: obj.additionalItems, + additionalProperties: obj.additionalProperties, + allOf: obj.allOf?.map((y) => toJson_JsonSchemaPropsV1Beta1(y)), + anyOf: obj.anyOf?.map((y) => toJson_JsonSchemaPropsV1Beta1(y)), + default: obj.default, + definitions: + obj.definitions === undefined + ? undefined + : Object.entries(obj.definitions).reduce( + (r, i) => + i[1] === undefined + ? r + : { ...r, [i[0]]: toJson_JsonSchemaPropsV1Beta1(i[1]) }, + {} + ), + dependencies: + obj.dependencies === undefined + ? undefined + : Object.entries(obj.dependencies).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + description: obj.description, + enum: obj.enum?.map((y) => y), + example: obj.example, + exclusiveMaximum: obj.exclusiveMaximum, + exclusiveMinimum: obj.exclusiveMinimum, + externalDocs: toJson_ExternalDocumentationV1Beta1(obj.externalDocs), + format: obj.format, + id: obj.id, + items: obj.items, + maxItems: obj.maxItems, + maxLength: obj.maxLength, + maxProperties: obj.maxProperties, + maximum: obj.maximum, + minItems: obj.minItems, + minLength: obj.minLength, + minProperties: obj.minProperties, + minimum: obj.minimum, + multipleOf: obj.multipleOf, + not: toJson_JsonSchemaPropsV1Beta1(obj.not), + nullable: obj.nullable, + oneOf: obj.oneOf?.map((y) => toJson_JsonSchemaPropsV1Beta1(y)), + pattern: obj.pattern, + patternProperties: + obj.patternProperties === undefined + ? undefined + : Object.entries(obj.patternProperties).reduce( + (r, i) => + i[1] === undefined + ? r + : { ...r, [i[0]]: toJson_JsonSchemaPropsV1Beta1(i[1]) }, + {} + ), + properties: + obj.properties === undefined + ? undefined + : Object.entries(obj.properties).reduce( + (r, i) => + i[1] === undefined + ? r + : { ...r, [i[0]]: toJson_JsonSchemaPropsV1Beta1(i[1]) }, + {} + ), + required: obj.required?.map((y) => y), + title: obj.title, + type: obj.type, + uniqueItems: obj.uniqueItems, + "x-kubernetes-embedded-resource": obj.xKubernetesEmbeddedResource, + "x-kubernetes-int-or-string": obj.xKubernetesIntOrString, + "x-kubernetes-list-map-keys": obj.xKubernetesListMapKeys?.map((y) => y), + "x-kubernetes-list-type": obj.xKubernetesListType, + "x-kubernetes-map-type": obj.xKubernetesMapType, + "x-kubernetes-preserve-unknown-fields": + obj.xKubernetesPreserveUnknownFields, + }; + // filter undefined values + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33841,22 +37745,28 @@ export interface HpaScalingPolicyV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.HPAScalingPolicy#value */ readonly value: number; - } /** * Converts an object of type 'HpaScalingPolicyV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HpaScalingPolicyV2Beta2(obj: HpaScalingPolicyV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HpaScalingPolicyV2Beta2( + obj: HpaScalingPolicyV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'periodSeconds': obj.periodSeconds, - 'type': obj.type, - 'value': obj.value, + periodSeconds: obj.periodSeconds, + type: obj.type, + value: obj.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33893,23 +37803,29 @@ export interface MetricTargetV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.MetricTarget#value */ readonly value?: Quantity; - } /** * Converts an object of type 'MetricTargetV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_MetricTargetV2Beta2(obj: MetricTargetV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_MetricTargetV2Beta2( + obj: MetricTargetV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'averageUtilization': obj.averageUtilization, - 'averageValue': obj.averageValue?.value, - 'type': obj.type, - 'value': obj.value?.value, + averageUtilization: obj.averageUtilization, + averageValue: obj.averageValue?.value, + type: obj.type, + value: obj.value?.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33932,21 +37848,27 @@ export interface MetricIdentifierV2Beta2 { * @schema io.k8s.api.autoscaling.v2beta2.MetricIdentifier#selector */ readonly selector?: LabelSelector; - } /** * Converts an object of type 'MetricIdentifierV2Beta2' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_MetricIdentifierV2Beta2(obj: MetricIdentifierV2Beta2 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_MetricIdentifierV2Beta2( + obj: MetricIdentifierV2Beta2 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'selector': toJson_LabelSelector(obj.selector), + name: obj.name, + selector: toJson_LabelSelector(obj.selector), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -33976,22 +37898,28 @@ export interface ConfigMapKeySelector { * @schema io.k8s.api.core.v1.ConfigMapKeySelector#optional */ readonly optional?: boolean; - } /** * Converts an object of type 'ConfigMapKeySelector' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ConfigMapKeySelector(obj: ConfigMapKeySelector | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ConfigMapKeySelector( + obj: ConfigMapKeySelector | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'key': obj.key, - 'name': obj.name, - 'optional': obj.optional, + key: obj.key, + name: obj.name, + optional: obj.optional, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34014,21 +37942,27 @@ export interface ObjectFieldSelector { * @schema io.k8s.api.core.v1.ObjectFieldSelector#fieldPath */ readonly fieldPath: string; - } /** * Converts an object of type 'ObjectFieldSelector' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ObjectFieldSelector(obj: ObjectFieldSelector | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ObjectFieldSelector( + obj: ObjectFieldSelector | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'apiVersion': obj.apiVersion, - 'fieldPath': obj.fieldPath, + apiVersion: obj.apiVersion, + fieldPath: obj.fieldPath, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34058,22 +37992,28 @@ export interface ResourceFieldSelector { * @schema io.k8s.api.core.v1.ResourceFieldSelector#resource */ readonly resource: string; - } /** * Converts an object of type 'ResourceFieldSelector' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ResourceFieldSelector(obj: ResourceFieldSelector | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ResourceFieldSelector( + obj: ResourceFieldSelector | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'containerName': obj.containerName, - 'divisor': obj.divisor?.value, - 'resource': obj.resource, + containerName: obj.containerName, + divisor: obj.divisor?.value, + resource: obj.resource, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34103,22 +38043,28 @@ export interface SecretKeySelector { * @schema io.k8s.api.core.v1.SecretKeySelector#optional */ readonly optional?: boolean; - } /** * Converts an object of type 'SecretKeySelector' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SecretKeySelector(obj: SecretKeySelector | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SecretKeySelector( + obj: SecretKeySelector | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'key': obj.key, - 'name': obj.name, - 'optional': obj.optional, + key: obj.key, + name: obj.name, + optional: obj.optional, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34141,21 +38087,27 @@ export interface HttpHeader { * @schema io.k8s.api.core.v1.HTTPHeader#value */ readonly value: string; - } /** * Converts an object of type 'HttpHeader' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HttpHeader(obj: HttpHeader | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HttpHeader( + obj: HttpHeader | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'value': obj.value, + name: obj.name, + value: obj.value, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34178,21 +38130,29 @@ export interface NodeSelectorTerm { * @schema io.k8s.api.core.v1.NodeSelectorTerm#matchFields */ readonly matchFields?: NodeSelectorRequirement[]; - } /** * Converts an object of type 'NodeSelectorTerm' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NodeSelectorTerm(obj: NodeSelectorTerm | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NodeSelectorTerm( + obj: NodeSelectorTerm | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'matchExpressions': obj.matchExpressions?.map(y => toJson_NodeSelectorRequirement(y)), - 'matchFields': obj.matchFields?.map(y => toJson_NodeSelectorRequirement(y)), + matchExpressions: obj.matchExpressions?.map((y) => + toJson_NodeSelectorRequirement(y) + ), + matchFields: obj.matchFields?.map((y) => toJson_NodeSelectorRequirement(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34215,21 +38175,27 @@ export interface PreferredSchedulingTerm { * @schema io.k8s.api.core.v1.PreferredSchedulingTerm#weight */ readonly weight: number; - } /** * Converts an object of type 'PreferredSchedulingTerm' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PreferredSchedulingTerm(obj: PreferredSchedulingTerm | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PreferredSchedulingTerm( + obj: PreferredSchedulingTerm | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'preference': toJson_NodeSelectorTerm(obj.preference), - 'weight': obj.weight, + preference: toJson_NodeSelectorTerm(obj.preference), + weight: obj.weight, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34252,21 +38218,27 @@ export interface WeightedPodAffinityTerm { * @schema io.k8s.api.core.v1.WeightedPodAffinityTerm#weight */ readonly weight: number; - } /** * Converts an object of type 'WeightedPodAffinityTerm' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_WeightedPodAffinityTerm(obj: WeightedPodAffinityTerm | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_WeightedPodAffinityTerm( + obj: WeightedPodAffinityTerm | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'podAffinityTerm': toJson_PodAffinityTerm(obj.podAffinityTerm), - 'weight': obj.weight, + podAffinityTerm: toJson_PodAffinityTerm(obj.podAffinityTerm), + weight: obj.weight, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34303,23 +38275,29 @@ export interface PodAffinityTerm { * @schema io.k8s.api.core.v1.PodAffinityTerm#topologyKey */ readonly topologyKey: string; - } /** * Converts an object of type 'PodAffinityTerm' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PodAffinityTerm(obj: PodAffinityTerm | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PodAffinityTerm( + obj: PodAffinityTerm | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'labelSelector': toJson_LabelSelector(obj.labelSelector), - 'namespaceSelector': toJson_LabelSelector(obj.namespaceSelector), - 'namespaces': obj.namespaces?.map(y => y), - 'topologyKey': obj.topologyKey, + labelSelector: toJson_LabelSelector(obj.labelSelector), + namespaceSelector: toJson_LabelSelector(obj.namespaceSelector), + namespaces: obj.namespaces?.map((y) => y), + topologyKey: obj.topologyKey, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34349,22 +38327,28 @@ export interface KeyToPath { * @schema io.k8s.api.core.v1.KeyToPath#path */ readonly path: string; - } /** * Converts an object of type 'KeyToPath' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_KeyToPath(obj: KeyToPath | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_KeyToPath( + obj: KeyToPath | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'key': obj.key, - 'mode': obj.mode, - 'path': obj.path, + key: obj.key, + mode: obj.mode, + path: obj.path, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34401,23 +38385,29 @@ export interface DownwardApiVolumeFile { * @schema io.k8s.api.core.v1.DownwardAPIVolumeFile#resourceFieldRef */ readonly resourceFieldRef?: ResourceFieldSelector; - } /** * Converts an object of type 'DownwardApiVolumeFile' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_DownwardApiVolumeFile(obj: DownwardApiVolumeFile | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_DownwardApiVolumeFile( + obj: DownwardApiVolumeFile | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'fieldRef': toJson_ObjectFieldSelector(obj.fieldRef), - 'mode': obj.mode, - 'path': obj.path, - 'resourceFieldRef': toJson_ResourceFieldSelector(obj.resourceFieldRef), + fieldRef: toJson_ObjectFieldSelector(obj.fieldRef), + mode: obj.mode, + path: obj.path, + resourceFieldRef: toJson_ResourceFieldSelector(obj.resourceFieldRef), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34440,21 +38430,27 @@ export interface PersistentVolumeClaimTemplate { * @schema io.k8s.api.core.v1.PersistentVolumeClaimTemplate#spec */ readonly spec: PersistentVolumeClaimSpec; - } /** * Converts an object of type 'PersistentVolumeClaimTemplate' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_PersistentVolumeClaimTemplate(obj: PersistentVolumeClaimTemplate | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_PersistentVolumeClaimTemplate( + obj: PersistentVolumeClaimTemplate | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'metadata': toJson_ObjectMeta(obj.metadata), - 'spec': toJson_PersistentVolumeClaimSpec(obj.spec), + metadata: toJson_ObjectMeta(obj.metadata), + spec: toJson_PersistentVolumeClaimSpec(obj.spec), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34491,23 +38487,31 @@ export interface VolumeProjection { * @schema io.k8s.api.core.v1.VolumeProjection#serviceAccountToken */ readonly serviceAccountToken?: ServiceAccountTokenProjection; - } /** * Converts an object of type 'VolumeProjection' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_VolumeProjection(obj: VolumeProjection | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_VolumeProjection( + obj: VolumeProjection | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'configMap': toJson_ConfigMapProjection(obj.configMap), - 'downwardAPI': toJson_DownwardApiProjection(obj.downwardApi), - 'secret': toJson_SecretProjection(obj.secret), - 'serviceAccountToken': toJson_ServiceAccountTokenProjection(obj.serviceAccountToken), + configMap: toJson_ConfigMapProjection(obj.configMap), + downwardAPI: toJson_DownwardApiProjection(obj.downwardApi), + secret: toJson_SecretProjection(obj.secret), + serviceAccountToken: toJson_ServiceAccountTokenProjection( + obj.serviceAccountToken + ), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34548,22 +38552,28 @@ export interface HttpIngressPathV1Beta1 { * @schema io.k8s.api.networking.v1beta1.HTTPIngressPath#pathType */ readonly pathType?: string; - } /** * Converts an object of type 'HttpIngressPathV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HttpIngressPathV1Beta1(obj: HttpIngressPathV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HttpIngressPathV1Beta1( + obj: HttpIngressPathV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'backend': toJson_IngressBackendV1Beta1(obj.backend), - 'path': obj.path, - 'pathType': obj.pathType, + backend: toJson_IngressBackendV1Beta1(obj.backend), + path: obj.path, + pathType: obj.pathType, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34593,22 +38603,28 @@ export interface QueuingConfigurationV1Beta1 { * @schema io.k8s.api.flowcontrol.v1beta1.QueuingConfiguration#queues */ readonly queues?: number; - } /** * Converts an object of type 'QueuingConfigurationV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_QueuingConfigurationV1Beta1(obj: QueuingConfigurationV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_QueuingConfigurationV1Beta1( + obj: QueuingConfigurationV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'handSize': obj.handSize, - 'queueLengthLimit': obj.queueLengthLimit, - 'queues': obj.queues, + handSize: obj.handSize, + queueLengthLimit: obj.queueLengthLimit, + queues: obj.queues, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34631,21 +38647,27 @@ export interface ServiceBackendPort { * @schema io.k8s.api.networking.v1.ServiceBackendPort#number */ readonly number?: number; - } /** * Converts an object of type 'ServiceBackendPort' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ServiceBackendPort(obj: ServiceBackendPort | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ServiceBackendPort( + obj: ServiceBackendPort | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'name': obj.name, - 'number': obj.number, + name: obj.name, + number: obj.number, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34685,22 +38707,28 @@ export interface HttpIngressPath { * @schema io.k8s.api.networking.v1.HTTPIngressPath#pathType */ readonly pathType?: string; - } /** * Converts an object of type 'HttpIngressPath' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_HttpIngressPath(obj: HttpIngressPath | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_HttpIngressPath( + obj: HttpIngressPath | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'backend': toJson_IngressBackend(obj.backend), - 'path': obj.path, - 'pathType': obj.pathType, + backend: toJson_IngressBackend(obj.backend), + path: obj.path, + pathType: obj.pathType, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -34723,21 +38751,27 @@ export interface IpBlock { * @schema io.k8s.api.networking.v1.IPBlock#except */ readonly except?: string[]; - } /** * Converts an object of type 'IpBlock' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_IpBlock(obj: IpBlock | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_IpBlock( + obj: IpBlock | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'cidr': obj.cidr, - 'except': obj.except?.map(y => y), + cidr: obj.cidr, + except: obj.except?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -35013,62 +39047,102 @@ export interface JsonSchemaProps { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.JSONSchemaProps#x-kubernetes-preserve-unknown-fields */ readonly xKubernetesPreserveUnknownFields?: boolean; - } /** * Converts an object of type 'JsonSchemaProps' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_JsonSchemaProps(obj: JsonSchemaProps | undefined): Record | undefined { - if (obj === undefined) { return undefined; } - const result = { - '$ref': obj.ref, - '$schema': obj.schema, - 'additionalItems': obj.additionalItems, - 'additionalProperties': obj.additionalProperties, - 'allOf': obj.allOf?.map(y => toJson_JsonSchemaProps(y)), - 'anyOf': obj.anyOf?.map(y => toJson_JsonSchemaProps(y)), - 'default': obj.default, - 'definitions': ((obj.definitions) === undefined) ? undefined : (Object.entries(obj.definitions).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: toJson_JsonSchemaProps(i[1]) }), {})), - 'dependencies': ((obj.dependencies) === undefined) ? undefined : (Object.entries(obj.dependencies).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {})), - 'description': obj.description, - 'enum': obj.enum?.map(y => y), - 'example': obj.example, - 'exclusiveMaximum': obj.exclusiveMaximum, - 'exclusiveMinimum': obj.exclusiveMinimum, - 'externalDocs': toJson_ExternalDocumentation(obj.externalDocs), - 'format': obj.format, - 'id': obj.id, - 'items': obj.items, - 'maxItems': obj.maxItems, - 'maxLength': obj.maxLength, - 'maxProperties': obj.maxProperties, - 'maximum': obj.maximum, - 'minItems': obj.minItems, - 'minLength': obj.minLength, - 'minProperties': obj.minProperties, - 'minimum': obj.minimum, - 'multipleOf': obj.multipleOf, - 'not': toJson_JsonSchemaProps(obj.not), - 'nullable': obj.nullable, - 'oneOf': obj.oneOf?.map(y => toJson_JsonSchemaProps(y)), - 'pattern': obj.pattern, - 'patternProperties': ((obj.patternProperties) === undefined) ? undefined : (Object.entries(obj.patternProperties).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: toJson_JsonSchemaProps(i[1]) }), {})), - 'properties': ((obj.properties) === undefined) ? undefined : (Object.entries(obj.properties).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: toJson_JsonSchemaProps(i[1]) }), {})), - 'required': obj.required?.map(y => y), - 'title': obj.title, - 'type': obj.type, - 'uniqueItems': obj.uniqueItems, - 'x-kubernetes-embedded-resource': obj.xKubernetesEmbeddedResource, - 'x-kubernetes-int-or-string': obj.xKubernetesIntOrString, - 'x-kubernetes-list-map-keys': obj.xKubernetesListMapKeys?.map(y => y), - 'x-kubernetes-list-type': obj.xKubernetesListType, - 'x-kubernetes-map-type': obj.xKubernetesMapType, - 'x-kubernetes-preserve-unknown-fields': obj.xKubernetesPreserveUnknownFields, - }; - // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); +export function toJson_JsonSchemaProps( + obj: JsonSchemaProps | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } + const result = { + $ref: obj.ref, + $schema: obj.schema, + additionalItems: obj.additionalItems, + additionalProperties: obj.additionalProperties, + allOf: obj.allOf?.map((y) => toJson_JsonSchemaProps(y)), + anyOf: obj.anyOf?.map((y) => toJson_JsonSchemaProps(y)), + default: obj.default, + definitions: + obj.definitions === undefined + ? undefined + : Object.entries(obj.definitions).reduce( + (r, i) => + i[1] === undefined + ? r + : { ...r, [i[0]]: toJson_JsonSchemaProps(i[1]) }, + {} + ), + dependencies: + obj.dependencies === undefined + ? undefined + : Object.entries(obj.dependencies).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ), + description: obj.description, + enum: obj.enum?.map((y) => y), + example: obj.example, + exclusiveMaximum: obj.exclusiveMaximum, + exclusiveMinimum: obj.exclusiveMinimum, + externalDocs: toJson_ExternalDocumentation(obj.externalDocs), + format: obj.format, + id: obj.id, + items: obj.items, + maxItems: obj.maxItems, + maxLength: obj.maxLength, + maxProperties: obj.maxProperties, + maximum: obj.maximum, + minItems: obj.minItems, + minLength: obj.minLength, + minProperties: obj.minProperties, + minimum: obj.minimum, + multipleOf: obj.multipleOf, + not: toJson_JsonSchemaProps(obj.not), + nullable: obj.nullable, + oneOf: obj.oneOf?.map((y) => toJson_JsonSchemaProps(y)), + pattern: obj.pattern, + patternProperties: + obj.patternProperties === undefined + ? undefined + : Object.entries(obj.patternProperties).reduce( + (r, i) => + i[1] === undefined + ? r + : { ...r, [i[0]]: toJson_JsonSchemaProps(i[1]) }, + {} + ), + properties: + obj.properties === undefined + ? undefined + : Object.entries(obj.properties).reduce( + (r, i) => + i[1] === undefined + ? r + : { ...r, [i[0]]: toJson_JsonSchemaProps(i[1]) }, + {} + ), + required: obj.required?.map((y) => y), + title: obj.title, + type: obj.type, + uniqueItems: obj.uniqueItems, + "x-kubernetes-embedded-resource": obj.xKubernetesEmbeddedResource, + "x-kubernetes-int-or-string": obj.xKubernetesIntOrString, + "x-kubernetes-list-map-keys": obj.xKubernetesListMapKeys?.map((y) => y), + "x-kubernetes-list-type": obj.xKubernetesListType, + "x-kubernetes-map-type": obj.xKubernetesMapType, + "x-kubernetes-preserve-unknown-fields": + obj.xKubernetesPreserveUnknownFields, + }; + // filter undefined values + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -35098,22 +39172,28 @@ export interface CustomResourceSubresourceScale { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.CustomResourceSubresourceScale#statusReplicasPath */ readonly statusReplicasPath: string; - } /** * Converts an object of type 'CustomResourceSubresourceScale' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_CustomResourceSubresourceScale(obj: CustomResourceSubresourceScale | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_CustomResourceSubresourceScale( + obj: CustomResourceSubresourceScale | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'labelSelectorPath': obj.labelSelectorPath, - 'specReplicasPath': obj.specReplicasPath, - 'statusReplicasPath': obj.statusReplicasPath, + labelSelectorPath: obj.labelSelectorPath, + specReplicasPath: obj.specReplicasPath, + statusReplicasPath: obj.statusReplicasPath, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -35132,21 +39212,27 @@ export interface ExternalDocumentationV1Beta1 { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1beta1.ExternalDocumentation#url */ readonly url?: string; - } /** * Converts an object of type 'ExternalDocumentationV1Beta1' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ExternalDocumentationV1Beta1(obj: ExternalDocumentationV1Beta1 | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ExternalDocumentationV1Beta1( + obj: ExternalDocumentationV1Beta1 | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'description': obj.description, - 'url': obj.url, + description: obj.description, + url: obj.url, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -35176,22 +39262,28 @@ export interface NodeSelectorRequirement { * @schema io.k8s.api.core.v1.NodeSelectorRequirement#values */ readonly values?: string[]; - } /** * Converts an object of type 'NodeSelectorRequirement' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_NodeSelectorRequirement(obj: NodeSelectorRequirement | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_NodeSelectorRequirement( + obj: NodeSelectorRequirement | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'key': obj.key, - 'operator': obj.operator, - 'values': obj.values?.map(y => y), + key: obj.key, + operator: obj.operator, + values: obj.values?.map((y) => y), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -35223,22 +39315,28 @@ export interface ConfigMapProjection { * @schema io.k8s.api.core.v1.ConfigMapProjection#optional */ readonly optional?: boolean; - } /** * Converts an object of type 'ConfigMapProjection' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ConfigMapProjection(obj: ConfigMapProjection | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ConfigMapProjection( + obj: ConfigMapProjection | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KeyToPath(y)), - 'name': obj.name, - 'optional': obj.optional, + items: obj.items?.map((y) => toJson_KeyToPath(y)), + name: obj.name, + optional: obj.optional, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -35254,20 +39352,26 @@ export interface DownwardApiProjection { * @schema io.k8s.api.core.v1.DownwardAPIProjection#items */ readonly items?: DownwardApiVolumeFile[]; - } /** * Converts an object of type 'DownwardApiProjection' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_DownwardApiProjection(obj: DownwardApiProjection | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_DownwardApiProjection( + obj: DownwardApiProjection | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_DownwardApiVolumeFile(y)), + items: obj.items?.map((y) => toJson_DownwardApiVolumeFile(y)), }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -35299,22 +39403,28 @@ export interface SecretProjection { * @schema io.k8s.api.core.v1.SecretProjection#optional */ readonly optional?: boolean; - } /** * Converts an object of type 'SecretProjection' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_SecretProjection(obj: SecretProjection | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_SecretProjection( + obj: SecretProjection | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'items': obj.items?.map(y => toJson_KeyToPath(y)), - 'name': obj.name, - 'optional': obj.optional, + items: obj.items?.map((y) => toJson_KeyToPath(y)), + name: obj.name, + optional: obj.optional, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -35345,22 +39455,28 @@ export interface ServiceAccountTokenProjection { * @schema io.k8s.api.core.v1.ServiceAccountTokenProjection#path */ readonly path: string; - } /** * Converts an object of type 'ServiceAccountTokenProjection' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ServiceAccountTokenProjection(obj: ServiceAccountTokenProjection | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ServiceAccountTokenProjection( + obj: ServiceAccountTokenProjection | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'audience': obj.audience, - 'expirationSeconds': obj.expirationSeconds, - 'path': obj.path, + audience: obj.audience, + expirationSeconds: obj.expirationSeconds, + path: obj.path, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ @@ -35379,21 +39495,26 @@ export interface ExternalDocumentation { * @schema io.k8s.apiextensions-apiserver.pkg.apis.apiextensions.v1.ExternalDocumentation#url */ readonly url?: string; - } /** * Converts an object of type 'ExternalDocumentation' to JSON representation. */ /* eslint-disable max-len, quote-props */ -export function toJson_ExternalDocumentation(obj: ExternalDocumentation | undefined): Record | undefined { - if (obj === undefined) { return undefined; } +export function toJson_ExternalDocumentation( + obj: ExternalDocumentation | undefined +): Record | undefined { + if (obj === undefined) { + return undefined; + } const result = { - 'description': obj.description, - 'url': obj.url, + description: obj.description, + url: obj.url, }; // filter undefined values - return Object.entries(result).reduce((r, i) => (i[1] === undefined) ? r : ({ ...r, [i[0]]: i[1] }), {}); + return Object.entries(result).reduce( + (r, i) => (i[1] === undefined ? r : { ...r, [i[0]]: i[1] }), + {} + ); } /* eslint-enable max-len, quote-props */ - diff --git a/cdk/kittyhawk/test/__snapshots__/application.test.ts.snap b/cdk/kittyhawk/test/__snapshots__/application.test.ts.snap deleted file mode 100644 index c7667676..00000000 --- a/cdk/kittyhawk/test/__snapshots__/application.test.ts.snap +++ /dev/null @@ -1,1371 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`Django Application -- Default 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 80, - "targetPort": 80, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "v1", - "kind": "ServiceAccount", - "metadata": Object { - "annotations": Object { - "eks.amazonaws.com/role-arn": "arn:aws:iam::TEST_AWS_ACCOUNT_ID:role/RELEASE_NAME", - }, - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "replicas": 1, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "DOMAINS", - "value": "platform.pennlabs.org", - }, - Object { - "name": "DJANGO_SETTINGS_MODULE", - "value": "Platform.settings.production", - }, - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "pennlabs/platform:TAG_FROM_CI", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 80, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, - Object { - "apiVersion": "networking.k8s.io/v1", - "kind": "Ingress", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "rules": Array [ - Object { - "host": "platform.pennlabs.org", - "http": Object { - "paths": Array [ - Object { - "backend": Object { - "service": Object { - "name": "RELEASE_NAME-platform", - "port": Object { - "number": 80, - }, - }, - }, - "path": "/", - "pathType": "Prefix", - }, - ], - }, - }, - ], - "tls": Array [ - Object { - "hosts": Array [ - "platform.pennlabs.org", - ], - "secretName": "platform-pennlabs-org-tls", - }, - ], - }, - }, - Object { - "apiVersion": "cert-manager.io/v1", - "kind": "Certificate", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/component": "certificate", - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "platform-pennlabs-org", - }, - "name": "platform-pennlabs-org", - }, - "spec": Object { - "dnsNames": Array [ - "platform.pennlabs.org", - "*.platform.pennlabs.org", - ], - "issuerRef": Object { - "group": "cert-manager.io", - "kind": "ClusterIssuer", - "name": "wildcard-letsencrypt-prod", - }, - "secretName": "platform-pennlabs-org-tls", - }, - }, -] -`; - -exports[`Django Application -- Duplicate Env 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 80, - "targetPort": 80, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "replicas": 1, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "DOMAIN", - "value": "platform.pennlabs.org", - }, - Object { - "name": "DOMAINS", - "value": "platform.pennlabs.org", - }, - Object { - "name": "DJANGO_SETTINGS_MODULE", - "value": "Platform.settings.production", - }, - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "pennlabs/platform:TAG_FROM_CI", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 80, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, - Object { - "apiVersion": "networking.k8s.io/v1", - "kind": "Ingress", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "rules": Array [ - Object { - "host": "platform.pennlabs.org", - "http": Object { - "paths": Array [ - Object { - "backend": Object { - "service": Object { - "name": "RELEASE_NAME-platform", - "port": Object { - "number": 80, - }, - }, - }, - "path": "/", - "pathType": "Prefix", - }, - ], - }, - }, - ], - "tls": Array [ - Object { - "hosts": Array [ - "platform.pennlabs.org", - ], - "secretName": "pennlabs-org-tls", - }, - ], - }, - }, - Object { - "apiVersion": "cert-manager.io/v1", - "kind": "Certificate", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/component": "certificate", - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "pennlabs-org", - }, - "name": "pennlabs-org", - }, - "spec": Object { - "dnsNames": Array [ - "pennlabs.org", - "*.pennlabs.org", - ], - "issuerRef": Object { - "group": "cert-manager.io", - "kind": "ClusterIssuer", - "name": "wildcard-letsencrypt-prod", - }, - "secretName": "pennlabs-org-tls", - }, - }, -] -`; - -exports[`Django Application -- Example 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 8080, - "targetPort": 8080, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "replicas": 2, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "SOME_ENV", - "value": "environment variables are cool", - }, - Object { - "name": "DOMAINS", - "value": "platform.pennlabs.org", - }, - Object { - "name": "DJANGO_SETTINGS_MODULE", - "value": "Platform.settings.production", - }, - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "pennlabs/platform:TAG_FROM_CI", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 8080, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, - Object { - "apiVersion": "networking.k8s.io/v1", - "kind": "Ingress", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "rules": Array [ - Object { - "host": "platform.pennlabs.org", - "http": Object { - "paths": Array [ - Object { - "backend": Object { - "service": Object { - "name": "RELEASE_NAME-platform", - "port": Object { - "number": 8080, - }, - }, - }, - "path": "/", - "pathType": "Prefix", - }, - ], - }, - }, - ], - "tls": Array [ - Object { - "hosts": Array [ - "platform.pennlabs.org", - ], - "secretName": "pennlabs-org-tls", - }, - ], - }, - }, - Object { - "apiVersion": "cert-manager.io/v1", - "kind": "Certificate", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/component": "certificate", - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "pennlabs-org", - }, - "name": "pennlabs-org", - }, - "spec": Object { - "dnsNames": Array [ - "pennlabs.org", - "*.pennlabs.org", - ], - "issuerRef": Object { - "group": "cert-manager.io", - "kind": "ClusterIssuer", - "name": "wildcard-letsencrypt-prod", - }, - "secretName": "pennlabs-org-tls", - }, - }, -] -`; - -exports[`Django Application -- Undefined Domains Chart 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 80, - "targetPort": 80, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-platform", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-platform", - }, - "spec": Object { - "replicas": 1, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-platform", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "DOMAIN", - "value": "platform.pennlabs.org", - }, - Object { - "name": "DJANGO_SETTINGS_MODULE", - "value": "Platform.settings.production", - }, - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "pennlabs/platform:TAG_FROM_CI", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 80, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, -] -`; - -exports[`React Application -- Default 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-react", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-react", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 80, - "targetPort": 80, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-react", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-react", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-react", - }, - "spec": Object { - "replicas": 1, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-react", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-react", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "DOMAIN", - "value": "pennclubs.com", - }, - Object { - "name": "PORT", - "value": "80", - }, - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "pennlabs/penn-clubs-frontend:TAG_FROM_CI", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 80, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, - Object { - "apiVersion": "networking.k8s.io/v1", - "kind": "Ingress", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-react", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-react", - }, - "spec": Object { - "rules": Array [ - Object { - "host": "pennclubs.com", - "http": Object { - "paths": Array [ - Object { - "backend": Object { - "service": Object { - "name": "RELEASE_NAME-react", - "port": Object { - "number": 80, - }, - }, - }, - "path": "/", - "pathType": "Prefix", - }, - ], - }, - }, - ], - "tls": Array [ - Object { - "hosts": Array [ - "pennclubs.com", - ], - "secretName": "pennclubs-com-tls", - }, - ], - }, - }, - Object { - "apiVersion": "cert-manager.io/v1", - "kind": "Certificate", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/component": "certificate", - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "pennclubs-com", - }, - "name": "pennclubs-com", - }, - "spec": Object { - "dnsNames": Array [ - "pennclubs.com", - "*.pennclubs.com", - ], - "issuerRef": Object { - "group": "cert-manager.io", - "kind": "ClusterIssuer", - "name": "wildcard-letsencrypt-prod", - }, - "secretName": "pennclubs-com-tls", - }, - }, -] -`; - -exports[`React Application -- Duplicate Env 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-react", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-react", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 80, - "targetPort": 80, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-react", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-react", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-react", - }, - "spec": Object { - "replicas": 2, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-react", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-react", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "DOMAIN", - "value": "pennclubs.com", - }, - Object { - "name": "DOMAIN", - "value": "pennclubs.com", - }, - Object { - "name": "PORT", - "value": "80", - }, - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "pennlabs/penn-clubs-frontend:TAG_FROM_CI", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 80, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, - Object { - "apiVersion": "networking.k8s.io/v1", - "kind": "Ingress", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-react", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-react", - }, - "spec": Object { - "rules": Array [ - Object { - "host": "pennclubs.com", - "http": Object { - "paths": Array [ - Object { - "backend": Object { - "service": Object { - "name": "RELEASE_NAME-react", - "port": Object { - "number": 80, - }, - }, - }, - "path": "/", - "pathType": "Prefix", - }, - ], - }, - }, - ], - "tls": Array [ - Object { - "hosts": Array [ - "pennclubs.com", - ], - "secretName": "pennclubs-com-tls", - }, - ], - }, - }, - Object { - "apiVersion": "cert-manager.io/v1", - "kind": "Certificate", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/component": "certificate", - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "pennclubs-com", - }, - "name": "pennclubs-com", - }, - "spec": Object { - "dnsNames": Array [ - "pennclubs.com", - "*.pennclubs.com", - ], - "issuerRef": Object { - "group": "cert-manager.io", - "kind": "ClusterIssuer", - "name": "wildcard-letsencrypt-prod", - }, - "secretName": "pennclubs-com-tls", - }, - }, -] -`; - -exports[`React Application -- Example 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-react", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-react", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 8080, - "targetPort": 8080, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-react", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-react", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-react", - }, - "spec": Object { - "replicas": 2, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-react", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-react", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "SOME_ENV", - "value": "environment variables are cool", - }, - Object { - "name": "DOMAIN", - "value": "pennclubs.com", - }, - Object { - "name": "PORT", - "value": "8080", - }, - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "pennlabs/penn-clubs-frontend:TAG_FROM_CI", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 8080, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, - Object { - "apiVersion": "networking.k8s.io/v1", - "kind": "Ingress", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-react", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-react", - }, - "spec": Object { - "rules": Array [ - Object { - "host": "pennclubs.com", - "http": Object { - "paths": Array [ - Object { - "backend": Object { - "service": Object { - "name": "RELEASE_NAME-react", - "port": Object { - "number": 8080, - }, - }, - }, - "path": "/", - "pathType": "Prefix", - }, - ], - }, - }, - ], - "tls": Array [ - Object { - "hosts": Array [ - "pennclubs.com", - ], - "secretName": "pennclubs-com-tls", - }, - ], - }, - }, - Object { - "apiVersion": "cert-manager.io/v1", - "kind": "Certificate", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/component": "certificate", - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "pennclubs-com", - }, - "name": "pennclubs-com", - }, - "spec": Object { - "dnsNames": Array [ - "pennclubs.com", - "*.pennclubs.com", - ], - "issuerRef": Object { - "group": "cert-manager.io", - "kind": "ClusterIssuer", - "name": "wildcard-letsencrypt-prod", - }, - "secretName": "pennclubs-com-tls", - }, - }, -] -`; - -exports[`Redis Application -- Default 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-redis", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-redis", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 6379, - "targetPort": 6379, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-redis", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-redis", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-redis", - }, - "spec": Object { - "replicas": 1, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-redis", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-redis", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "redis:6.0", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 6379, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, -] -`; - -exports[`Redis Application -- Example 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-redis", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-redis", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 6380, - "targetPort": 6380, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-redis", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "v1", - "kind": "ServiceAccount", - "metadata": Object { - "annotations": Object { - "eks.amazonaws.com/role-arn": "arn:aws:iam::TEST_AWS_ACCOUNT_ID:role/RELEASE_NAME", - }, - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-redis", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-redis", - }, - "spec": Object { - "replicas": 1, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-redis", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-redis", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "custom-redis-image:5.0", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 6380, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, -] -`; - -exports[`Tag Override 1`] = ` -Array [ - Object { - "apiVersion": "v1", - "kind": "Service", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-serve", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-serve", - }, - "spec": Object { - "ports": Array [ - Object { - "port": 80, - "targetPort": 80, - }, - ], - "selector": Object { - "app.kubernetes.io/name": "RELEASE_NAME-serve", - }, - "type": "ClusterIP", - }, - }, - Object { - "apiVersion": "apps/v1", - "kind": "Deployment", - "metadata": Object { - "labels": Object { - "app.kubernetes.io/managed-by": "kittyhawk", - "app.kubernetes.io/name": "RELEASE_NAME-serve", - "app.kubernetes.io/part-of": "RELEASE_NAME", - "app.kubernetes.io/version": "TAG_FROM_CI", - }, - "name": "RELEASE_NAME-serve", - }, - "spec": Object { - "replicas": 1, - "selector": Object { - "matchLabels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-serve", - }, - }, - "strategy": Object { - "rollingUpdate": Object { - "maxSurge": 3, - "maxUnavailable": 0, - }, - "type": "RollingUpdate", - }, - "template": Object { - "metadata": Object { - "labels": Object { - "app.kubernetes.io/name": "RELEASE_NAME-serve", - }, - }, - "spec": Object { - "containers": Array [ - Object { - "env": Array [ - Object { - "name": "GIT_SHA", - "value": "TAG_FROM_CI", - }, - ], - "image": "pennlabs/website:latest", - "imagePullPolicy": "IfNotPresent", - "name": "worker", - "ports": Array [ - Object { - "containerPort": 80, - }, - ], - }, - ], - "volumes": Array [], - }, - }, - }, - }, -] -`; diff --git a/cdk/kittyhawk/test/__snapshots__/cronjob.test.ts.snap b/cdk/kittyhawk/test/__snapshots__/cronjob.test.ts.snap index eeb26e80..c3119cbf 100644 --- a/cdk/kittyhawk/test/__snapshots__/cronjob.test.ts.snap +++ b/cdk/kittyhawk/test/__snapshots__/cronjob.test.ts.snap @@ -57,6 +57,64 @@ Array [ ] `; +exports[`Cron Job with service account 1`] = ` +Array [ + Object { + "apiVersion": "batch/v1", + "kind": "CronJob", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-calculate-waits", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-calculate-waits", + }, + "spec": Object { + "failedJobsHistoryLimit": 1, + "jobTemplate": Object { + "spec": Object { + "template": Object { + "spec": Object { + "containers": Array [ + Object { + "command": Array [ + "python", + "manage.py", + "calculatewaittimes", + ], + "env": Array [ + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "envFrom": Array [ + Object { + "secretRef": Object { + "name": "penn-courses", + }, + }, + ], + "image": "pennlabs/penn-courses-backend:TAG_FROM_CI", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + }, + ], + "restartPolicy": "Never", + "serviceAccountName": "RELEASE_NAME", + }, + }, + }, + }, + "schedule": "*/5 * * * *", + "successfulJobsHistoryLimit": 1, + }, + }, +] +`; + exports[`Cron Job with volume 1`] = ` Array [ Object { diff --git a/cdk/kittyhawk/test/__snapshots__/deployment.test.ts.snap b/cdk/kittyhawk/test/__snapshots__/deployment.test.ts.snap new file mode 100644 index 00000000..fc8ebc4c --- /dev/null +++ b/cdk/kittyhawk/test/__snapshots__/deployment.test.ts.snap @@ -0,0 +1,138 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Container -- Default 1`] = `Array []`; + +exports[`Deployment -- Default 1`] = ` +Array [ + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "container", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "container", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "container", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "container", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/website:latest", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 80, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, +] +`; + +exports[`Deployment -- With Service Account 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "ServiceAccount", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "service-account", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "container", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "container", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "container", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "container", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/website:latest", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 80, + }, + ], + }, + ], + "serviceAccountName": "service-account", + "volumes": Array [], + }, + }, + }, + }, +] +`; diff --git a/cdk/kittyhawk/test/application.test.ts b/cdk/kittyhawk/test/application.test.ts deleted file mode 100644 index 4d6b86a8..00000000 --- a/cdk/kittyhawk/test/application.test.ts +++ /dev/null @@ -1,192 +0,0 @@ -import { Construct } from "constructs"; -import { HostRules } from "../src"; -import { - Application, - DjangoApplication, - ReactApplication, - RedisApplication, -} from "../src/application"; -import { NonEmptyArray } from "../src/utils"; -import { - chartTest, - failingTestNoAWSAccountId, - failingTestNoGitSha, -} from "./utils"; - -export function buildTagOverrideChart(scope: Construct) { - /** Overrides the image tag set as env var **/ - new Application(scope, "serve", { - deployment: { - image: "pennlabs/website", - tag: "latest", - }, - }); -} -export function buildSimpleChart(scope: Construct) { - /** Overrides the image tag set as env var **/ - new Application(scope, "serve", { - deployment: { - image: "pennlabs/website", - }, - }); -} - -test("Application -- No Git Sha", () => failingTestNoGitSha(buildSimpleChart)); -test("Application -- No ServiceAccount But CreateServiceAccount", () => - failingTestNoAWSAccountId(buildRedisChartExample)); - -function buildRedisChartDefault(scope: Construct) { - new RedisApplication(scope, "redis", testConfig.redis.default); -} -function buildRedisChartExample(scope: Construct) { - new RedisApplication(scope, "redis", testConfig.redis.example); -} - -function buildDjangoChartDefault(scope: Construct) { - new DjangoApplication(scope, "platform", testConfig.django.default); -} -function buildDjangoChartExample(scope: Construct) { - new DjangoApplication(scope, "platform", testConfig.django.example); -} -function buildDjangoIngressUndefinedDomainsChart(scope: Construct) { - new DjangoApplication(scope, "platform", testConfig.django.undefinedDomains); -} -function buildDjangoChartDuplicateEnv(scope: Construct) { - new DjangoApplication(scope, "platform", testConfig.django.duplicateEnv); -} -function buildReactChartDefault(scope: Construct) { - new ReactApplication(scope, "react", testConfig.react.default); -} -function buildReactChartExample(scope: Construct) { - new ReactApplication(scope, "react", testConfig.react.example); -} -function buildReactChartDuplicateEnv(scope: Construct) { - new ReactApplication(scope, "react", testConfig.react.duplicateEnv); -} - -test("Tag Override", () => chartTest(buildTagOverrideChart)); - -test("Redis Application -- Default", () => chartTest(buildRedisChartDefault)); -test("Redis Application -- Example", () => chartTest(buildRedisChartExample)); - -test("Django Application -- Default", () => chartTest(buildDjangoChartDefault)); -test("Django Application -- Example", () => chartTest(buildDjangoChartExample)); -test("Django Application -- Duplicate Env", () => - chartTest(buildDjangoChartDuplicateEnv)); -test("Django Application -- Undefined Domains Chart", () => - chartTest(buildDjangoIngressUndefinedDomainsChart)); - -test("React Application -- Default", () => chartTest(buildReactChartDefault)); -test("React Application -- Example", () => chartTest(buildReactChartExample)); -test("React Application -- Duplicate Env", () => - chartTest(buildReactChartDuplicateEnv)); - -/** - * Test Configuration for RedisApplication - * - * default - assumes the default values for the configuration - * example - uses the customized values for the configuration - */ -const redisTestConfig = { - default: {}, - example: { - deployment: { - image: "custom-redis-image", - tag: "5.0", - }, - port: 6380, - createServiceAccount: true, - }, -}; - -/** - * Test Configuration for DjangoApplication - * - * default - assumes mostly default values for the configuration - * example - sample parameters - * undefinedDomains - domains is undefined, no ingress required (example: celery on courses backend) - * duplicateEnv - env is defined twice, should not throw an error - * */ -const djangoTestConfig = { - default: { - deployment: { - image: "pennlabs/platform", - }, - domains: [ - { host: "platform.pennlabs.org", paths: ["/"] }, - ] as NonEmptyArray, - djangoSettingsModule: "Platform.settings.production", - createServiceAccount: true, - }, - example: { - deployment: { - image: "pennlabs/platform", - replicas: 2, - env: [{ name: "SOME_ENV", value: "environment variables are cool" }], - }, - domains: [ - { host: "platform.pennlabs.org", isSubdomain: true, paths: ["/"] }, - ] as NonEmptyArray, - djangoSettingsModule: "Platform.settings.production", - port: 8080, - }, - duplicateEnv: { - deployment: { - image: "pennlabs/platform", - env: [{ name: "DOMAIN", value: "platform.pennlabs.org" }], - }, - domains: [ - { host: "platform.pennlabs.org", isSubdomain: true, paths: ["/"] }, - ] as NonEmptyArray, - djangoSettingsModule: "Platform.settings.production", - }, - undefinedDomains: { - deployment: { - image: "pennlabs/platform", - env: [{ name: "DOMAIN", value: "platform.pennlabs.org" }], - }, - domains: undefined, - djangoSettingsModule: "Platform.settings.production", - }, -}; - -/** - * Test Configuration for ReactApplication - * - * default - assumes mostly default values for the configuration - * example - sample parameters - * duplicateEnv - env is defined twice, should not throw an error - */ -const reactTestConfig = { - default: { - deployment: { - image: "pennlabs/penn-clubs-frontend", - }, - domain: { host: "pennclubs.com", paths: ["/"] }, - ingressPaths: ["/"], - }, - example: { - deployment: { - image: "pennlabs/penn-clubs-frontend", - replicas: 2, - env: [{ name: "SOME_ENV", value: "environment variables are cool" }], - }, - domain: { host: "pennclubs.com", paths: ["/"] }, - port: 8080, - }, - duplicateEnv: { - deployment: { - image: "pennlabs/penn-clubs-frontend", - replicas: 2, - env: [{ name: "DOMAIN", value: "pennclubs.com" }], - }, - domain: { host: "pennclubs.com", paths: ["/"] }, - port: 80, - }, -}; - -const testConfig = { - redis: redisTestConfig, - django: djangoTestConfig, - react: reactTestConfig, -}; diff --git a/cdk/kittyhawk/test/application/__snapshots__/application.test.ts.snap b/cdk/kittyhawk/test/application/__snapshots__/application.test.ts.snap new file mode 100644 index 00000000..21476583 --- /dev/null +++ b/cdk/kittyhawk/test/application/__snapshots__/application.test.ts.snap @@ -0,0 +1,87 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Tag Override 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-serve", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-serve", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 80, + "targetPort": 80, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-serve", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-serve", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-serve", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-serve", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-serve", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/website:latest", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 80, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, +] +`; diff --git a/cdk/kittyhawk/test/application/__snapshots__/django.test.ts.snap b/cdk/kittyhawk/test/application/__snapshots__/django.test.ts.snap new file mode 100644 index 00000000..14ffcf99 --- /dev/null +++ b/cdk/kittyhawk/test/application/__snapshots__/django.test.ts.snap @@ -0,0 +1,604 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Django Application -- Default 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 80, + "targetPort": 80, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "v1", + "kind": "ServiceAccount", + "metadata": Object { + "annotations": Object { + "eks.amazonaws.com/role-arn": "arn:aws:iam::TEST_AWS_ACCOUNT_ID:role/RELEASE_NAME", + }, + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "DOMAINS", + "value": "platform.pennlabs.org", + }, + Object { + "name": "DJANGO_SETTINGS_MODULE", + "value": "Platform.settings.production", + }, + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/platform:TAG_FROM_CI", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 80, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, + Object { + "apiVersion": "networking.k8s.io/v1", + "kind": "Ingress", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "rules": Array [ + Object { + "host": "platform.pennlabs.org", + "http": Object { + "paths": Array [ + Object { + "backend": Object { + "service": Object { + "name": "RELEASE_NAME-platform", + "port": Object { + "number": 80, + }, + }, + }, + "path": "/", + "pathType": "Prefix", + }, + ], + }, + }, + ], + "tls": Array [ + Object { + "hosts": Array [ + "platform.pennlabs.org", + ], + "secretName": "platform-pennlabs-org-tls", + }, + ], + }, + }, + Object { + "apiVersion": "cert-manager.io/v1", + "kind": "Certificate", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/component": "certificate", + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "platform-pennlabs-org", + }, + "name": "platform-pennlabs-org", + }, + "spec": Object { + "dnsNames": Array [ + "platform.pennlabs.org", + "*.platform.pennlabs.org", + ], + "issuerRef": Object { + "group": "cert-manager.io", + "kind": "ClusterIssuer", + "name": "wildcard-letsencrypt-prod", + }, + "secretName": "platform-pennlabs-org-tls", + }, + }, +] +`; + +exports[`Django Application -- Duplicate Env 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 80, + "targetPort": 80, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "DOMAIN", + "value": "platform.pennlabs.org", + }, + Object { + "name": "DOMAINS", + "value": "platform.pennlabs.org", + }, + Object { + "name": "DJANGO_SETTINGS_MODULE", + "value": "Platform.settings.production", + }, + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/platform:TAG_FROM_CI", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 80, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, + Object { + "apiVersion": "networking.k8s.io/v1", + "kind": "Ingress", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "rules": Array [ + Object { + "host": "platform.pennlabs.org", + "http": Object { + "paths": Array [ + Object { + "backend": Object { + "service": Object { + "name": "RELEASE_NAME-platform", + "port": Object { + "number": 80, + }, + }, + }, + "path": "/", + "pathType": "Prefix", + }, + ], + }, + }, + ], + "tls": Array [ + Object { + "hosts": Array [ + "platform.pennlabs.org", + ], + "secretName": "pennlabs-org-tls", + }, + ], + }, + }, + Object { + "apiVersion": "cert-manager.io/v1", + "kind": "Certificate", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/component": "certificate", + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "pennlabs-org", + }, + "name": "pennlabs-org", + }, + "spec": Object { + "dnsNames": Array [ + "pennlabs.org", + "*.pennlabs.org", + ], + "issuerRef": Object { + "group": "cert-manager.io", + "kind": "ClusterIssuer", + "name": "wildcard-letsencrypt-prod", + }, + "secretName": "pennlabs-org-tls", + }, + }, +] +`; + +exports[`Django Application -- Example 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 8080, + "targetPort": 8080, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "replicas": 2, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "SOME_ENV", + "value": "environment variables are cool", + }, + Object { + "name": "DOMAINS", + "value": "platform.pennlabs.org", + }, + Object { + "name": "DJANGO_SETTINGS_MODULE", + "value": "Platform.settings.production", + }, + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/platform:TAG_FROM_CI", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 8080, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, + Object { + "apiVersion": "networking.k8s.io/v1", + "kind": "Ingress", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "rules": Array [ + Object { + "host": "platform.pennlabs.org", + "http": Object { + "paths": Array [ + Object { + "backend": Object { + "service": Object { + "name": "RELEASE_NAME-platform", + "port": Object { + "number": 8080, + }, + }, + }, + "path": "/", + "pathType": "Prefix", + }, + ], + }, + }, + ], + "tls": Array [ + Object { + "hosts": Array [ + "platform.pennlabs.org", + ], + "secretName": "pennlabs-org-tls", + }, + ], + }, + }, + Object { + "apiVersion": "cert-manager.io/v1", + "kind": "Certificate", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/component": "certificate", + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "pennlabs-org", + }, + "name": "pennlabs-org", + }, + "spec": Object { + "dnsNames": Array [ + "pennlabs.org", + "*.pennlabs.org", + ], + "issuerRef": Object { + "group": "cert-manager.io", + "kind": "ClusterIssuer", + "name": "wildcard-letsencrypt-prod", + }, + "secretName": "pennlabs-org-tls", + }, + }, +] +`; + +exports[`Django Application -- Undefined Domains Chart 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 80, + "targetPort": 80, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-platform", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-platform", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-platform", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "DOMAIN", + "value": "platform.pennlabs.org", + }, + Object { + "name": "DJANGO_SETTINGS_MODULE", + "value": "Platform.settings.production", + }, + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/platform:TAG_FROM_CI", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 80, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, +] +`; diff --git a/cdk/kittyhawk/test/application/__snapshots__/react.test.ts.snap b/cdk/kittyhawk/test/application/__snapshots__/react.test.ts.snap new file mode 100644 index 00000000..3bd460c5 --- /dev/null +++ b/cdk/kittyhawk/test/application/__snapshots__/react.test.ts.snap @@ -0,0 +1,495 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`React Application -- Default 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-react", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-react", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 80, + "targetPort": 80, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-react", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-react", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-react", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-react", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-react", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "DOMAIN", + "value": "pennclubs.com", + }, + Object { + "name": "PORT", + "value": "80", + }, + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/penn-clubs-frontend:TAG_FROM_CI", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 80, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, + Object { + "apiVersion": "networking.k8s.io/v1", + "kind": "Ingress", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-react", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-react", + }, + "spec": Object { + "rules": Array [ + Object { + "host": "pennclubs.com", + "http": Object { + "paths": Array [ + Object { + "backend": Object { + "service": Object { + "name": "RELEASE_NAME-react", + "port": Object { + "number": 80, + }, + }, + }, + "path": "/", + "pathType": "Prefix", + }, + ], + }, + }, + ], + "tls": Array [ + Object { + "hosts": Array [ + "pennclubs.com", + ], + "secretName": "pennclubs-com-tls", + }, + ], + }, + }, + Object { + "apiVersion": "cert-manager.io/v1", + "kind": "Certificate", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/component": "certificate", + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "pennclubs-com", + }, + "name": "pennclubs-com", + }, + "spec": Object { + "dnsNames": Array [ + "pennclubs.com", + "*.pennclubs.com", + ], + "issuerRef": Object { + "group": "cert-manager.io", + "kind": "ClusterIssuer", + "name": "wildcard-letsencrypt-prod", + }, + "secretName": "pennclubs-com-tls", + }, + }, +] +`; + +exports[`React Application -- Duplicate Env 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-react", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-react", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 80, + "targetPort": 80, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-react", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-react", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-react", + }, + "spec": Object { + "replicas": 2, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-react", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-react", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "DOMAIN", + "value": "pennclubs.com", + }, + Object { + "name": "DOMAIN", + "value": "pennclubs.com", + }, + Object { + "name": "PORT", + "value": "80", + }, + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/penn-clubs-frontend:TAG_FROM_CI", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 80, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, + Object { + "apiVersion": "networking.k8s.io/v1", + "kind": "Ingress", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-react", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-react", + }, + "spec": Object { + "rules": Array [ + Object { + "host": "pennclubs.com", + "http": Object { + "paths": Array [ + Object { + "backend": Object { + "service": Object { + "name": "RELEASE_NAME-react", + "port": Object { + "number": 80, + }, + }, + }, + "path": "/", + "pathType": "Prefix", + }, + ], + }, + }, + ], + "tls": Array [ + Object { + "hosts": Array [ + "pennclubs.com", + ], + "secretName": "pennclubs-com-tls", + }, + ], + }, + }, + Object { + "apiVersion": "cert-manager.io/v1", + "kind": "Certificate", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/component": "certificate", + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "pennclubs-com", + }, + "name": "pennclubs-com", + }, + "spec": Object { + "dnsNames": Array [ + "pennclubs.com", + "*.pennclubs.com", + ], + "issuerRef": Object { + "group": "cert-manager.io", + "kind": "ClusterIssuer", + "name": "wildcard-letsencrypt-prod", + }, + "secretName": "pennclubs-com-tls", + }, + }, +] +`; + +exports[`React Application -- Example 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-react", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-react", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 8080, + "targetPort": 8080, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-react", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-react", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-react", + }, + "spec": Object { + "replicas": 2, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-react", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-react", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "SOME_ENV", + "value": "environment variables are cool", + }, + Object { + "name": "DOMAIN", + "value": "pennclubs.com", + }, + Object { + "name": "PORT", + "value": "8080", + }, + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "pennlabs/penn-clubs-frontend:TAG_FROM_CI", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 8080, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, + Object { + "apiVersion": "networking.k8s.io/v1", + "kind": "Ingress", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-react", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-react", + }, + "spec": Object { + "rules": Array [ + Object { + "host": "pennclubs.com", + "http": Object { + "paths": Array [ + Object { + "backend": Object { + "service": Object { + "name": "RELEASE_NAME-react", + "port": Object { + "number": 8080, + }, + }, + }, + "path": "/", + "pathType": "Prefix", + }, + ], + }, + }, + ], + "tls": Array [ + Object { + "hosts": Array [ + "pennclubs.com", + ], + "secretName": "pennclubs-com-tls", + }, + ], + }, + }, + Object { + "apiVersion": "cert-manager.io/v1", + "kind": "Certificate", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/component": "certificate", + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "pennclubs-com", + }, + "name": "pennclubs-com", + }, + "spec": Object { + "dnsNames": Array [ + "pennclubs.com", + "*.pennclubs.com", + ], + "issuerRef": Object { + "group": "cert-manager.io", + "kind": "ClusterIssuer", + "name": "wildcard-letsencrypt-prod", + }, + "secretName": "pennclubs-com-tls", + }, + }, +] +`; diff --git a/cdk/kittyhawk/test/application/__snapshots__/redis.test.ts.snap b/cdk/kittyhawk/test/application/__snapshots__/redis.test.ts.snap new file mode 100644 index 00000000..f93fb334 --- /dev/null +++ b/cdk/kittyhawk/test/application/__snapshots__/redis.test.ts.snap @@ -0,0 +1,620 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Redis Application -- Custom ConfigMap 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "data": Object { + "redis-config": "custom-config", + }, + "kind": "ConfigMap", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "custom-config-map", + }, + }, + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 6379, + "targetPort": 6379, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "redis:6.0", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 6379, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, +] +`; + +exports[`Redis Application -- Default 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 6379, + "targetPort": 6379, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "redis:6.0", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 6379, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, +] +`; + +exports[`Redis Application -- Example 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 6380, + "targetPort": 6380, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "v1", + "kind": "ServiceAccount", + "metadata": Object { + "annotations": Object { + "eks.amazonaws.com/role-arn": "arn:aws:iam::TEST_AWS_ACCOUNT_ID:role/RELEASE_NAME", + }, + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "custom-redis-image:5.0", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 6380, + }, + ], + }, + ], + "volumes": Array [], + }, + }, + }, + }, +] +`; + +exports[`Redis Application -- Persistence 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "PersistentVolume", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis-pv", + }, + "spec": Object { + "accessModes": Array [ + "ReadWriteMany", + ], + "capacity": Object { + "storage": "1Gi", + }, + "hostPath": Object { + "path": "/RELEASE_NAME/redis", + }, + "storageClassName": "RELEASE_NAME-redis-storage", + }, + }, + Object { + "apiVersion": "v1", + "kind": "PersistentVolumeClaim", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis-pvc", + }, + "spec": Object { + "accessModes": Array [ + "ReadWriteMany", + ], + "resources": Object { + "requests": Object { + "storage": "1Gi", + }, + }, + "storageClassName": "RELEASE_NAME-redis-storage", + }, + }, + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 6379, + "targetPort": 6379, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "redis:6.0", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 6379, + }, + ], + "volumeMounts": Array [ + Object { + "mountPath": "/redis-master-data", + "name": "data", + }, + Object { + "mountPath": "/redis-master", + "name": "config", + }, + ], + }, + ], + "volumes": Array [ + Object { + "name": "data", + "persistentVolumeClaim": Object { + "claimName": "RELEASE_NAME-redis-pvc", + }, + }, + Object { + "configMap": Object { + "items": Array [ + Object { + "key": "redis-config", + "path": "redis.conf", + }, + ], + "name": "redis-config", + }, + "name": "config", + }, + ], + }, + }, + }, + }, +] +`; + +exports[`Redis Application -- Persistence with Custom Volumes 1`] = ` +Array [ + Object { + "apiVersion": "v1", + "kind": "PersistentVolume", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis-pv", + }, + "spec": Object { + "accessModes": Array [ + "ReadWriteMany", + ], + "capacity": Object { + "storage": "1Gi", + }, + "hostPath": Object { + "path": "/RELEASE_NAME/redis", + }, + "storageClassName": "RELEASE_NAME-redis-storage", + }, + }, + Object { + "apiVersion": "v1", + "kind": "PersistentVolumeClaim", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis-pvc", + }, + "spec": Object { + "accessModes": Array [ + "ReadWriteMany", + ], + "resources": Object { + "requests": Object { + "storage": "1Gi", + }, + }, + "storageClassName": "RELEASE_NAME-redis-storage", + }, + }, + Object { + "apiVersion": "v1", + "kind": "Service", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "ports": Array [ + Object { + "port": 6379, + "targetPort": 6379, + }, + ], + "selector": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + "type": "ClusterIP", + }, + }, + Object { + "apiVersion": "apps/v1", + "kind": "Deployment", + "metadata": Object { + "labels": Object { + "app.kubernetes.io/managed-by": "kittyhawk", + "app.kubernetes.io/name": "RELEASE_NAME-redis", + "app.kubernetes.io/part-of": "RELEASE_NAME", + "app.kubernetes.io/version": "TAG_FROM_CI", + }, + "name": "RELEASE_NAME-redis", + }, + "spec": Object { + "replicas": 1, + "selector": Object { + "matchLabels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "strategy": Object { + "rollingUpdate": Object { + "maxSurge": 3, + "maxUnavailable": 0, + }, + "type": "RollingUpdate", + }, + "template": Object { + "metadata": Object { + "labels": Object { + "app.kubernetes.io/name": "RELEASE_NAME-redis", + }, + }, + "spec": Object { + "containers": Array [ + Object { + "env": Array [ + Object { + "name": "GIT_SHA", + "value": "TAG_FROM_CI", + }, + ], + "image": "redis:6.0", + "imagePullPolicy": "IfNotPresent", + "name": "worker", + "ports": Array [ + Object { + "containerPort": 6379, + }, + ], + "volumeMounts": Array [ + Object { + "mountPath": "/etc/redis", + "name": "example-mount-secret", + }, + Object { + "mountPath": "/etc/volumes", + "name": "example-mount", + }, + ], + }, + ], + "volumes": Array [ + Object { + "name": "example-mount-secret", + "secret": Object { + "items": Array [], + "secretName": "example-mount-secret", + }, + }, + Object { + "name": "data", + "persistentVolumeClaim": Object { + "claimName": "RELEASE_NAME-redis-pvc", + }, + }, + Object { + "configMap": Object { + "items": Array [ + Object { + "key": "redis-config", + "path": "redis.conf", + }, + ], + "name": "redis-config", + }, + "name": "config", + }, + ], + }, + }, + }, + }, +] +`; diff --git a/cdk/kittyhawk/test/application/application.test.ts b/cdk/kittyhawk/test/application/application.test.ts new file mode 100644 index 00000000..c536bbc1 --- /dev/null +++ b/cdk/kittyhawk/test/application/application.test.ts @@ -0,0 +1,24 @@ +import { Construct } from "constructs"; +import { Application } from "../../src/application"; +import { chartTest, failingTestNoGitSha } from "../utils"; + +export function buildTagOverrideChart(scope: Construct) { + /** Overrides the image tag set as env var **/ + new Application(scope, "serve", { + deployment: { + image: "pennlabs/website", + tag: "latest", + }, + }); +} +export function buildSimpleChart(scope: Construct) { + /** Overrides the image tag set as env var **/ + new Application(scope, "serve", { + deployment: { + image: "pennlabs/website", + }, + }); +} + +test("Application -- No Git Sha", () => failingTestNoGitSha(buildSimpleChart)); +test("Tag Override", () => chartTest(buildTagOverrideChart)); diff --git a/cdk/kittyhawk/test/application/django.test.ts b/cdk/kittyhawk/test/application/django.test.ts new file mode 100644 index 00000000..764078b4 --- /dev/null +++ b/cdk/kittyhawk/test/application/django.test.ts @@ -0,0 +1,76 @@ +import { Construct } from "constructs"; +import { HostRules } from "../../src"; +import { DjangoApplication } from "../../src/application"; +import { NonEmptyArray } from "../../src/utils"; +import { chartTest } from "../utils"; + +/** + * Test Configuration for DjangoApplication + * + * default - assumes mostly default values for the configuration + * example - sample parameters + * undefinedDomains - domains is undefined, no ingress required (example: celery on courses backend) + * duplicateEnv - env is defined twice, should not throw an error + * */ +const djangoTestConfig = { + default: { + deployment: { + image: "pennlabs/platform", + }, + domains: [ + { host: "platform.pennlabs.org", paths: ["/"] }, + ] as NonEmptyArray, + djangoSettingsModule: "Platform.settings.production", + createServiceAccount: true, + }, + example: { + deployment: { + image: "pennlabs/platform", + replicas: 2, + env: [{ name: "SOME_ENV", value: "environment variables are cool" }], + }, + domains: [ + { host: "platform.pennlabs.org", isSubdomain: true, paths: ["/"] }, + ] as NonEmptyArray, + djangoSettingsModule: "Platform.settings.production", + port: 8080, + }, + duplicateEnv: { + deployment: { + image: "pennlabs/platform", + env: [{ name: "DOMAIN", value: "platform.pennlabs.org" }], + }, + domains: [ + { host: "platform.pennlabs.org", isSubdomain: true, paths: ["/"] }, + ] as NonEmptyArray, + djangoSettingsModule: "Platform.settings.production", + }, + undefinedDomains: { + deployment: { + image: "pennlabs/platform", + env: [{ name: "DOMAIN", value: "platform.pennlabs.org" }], + }, + domains: undefined, + djangoSettingsModule: "Platform.settings.production", + }, +}; + +test("Django Application -- Default", () => chartTest(buildDjangoChartDefault)); +test("Django Application -- Example", () => chartTest(buildDjangoChartExample)); +test("Django Application -- Duplicate Env", () => + chartTest(buildDjangoChartDuplicateEnv)); +test("Django Application -- Undefined Domains Chart", () => + chartTest(buildDjangoIngressUndefinedDomainsChart)); + +function buildDjangoChartDefault(scope: Construct) { + new DjangoApplication(scope, "platform", djangoTestConfig.default); +} +function buildDjangoChartExample(scope: Construct) { + new DjangoApplication(scope, "platform", djangoTestConfig.example); +} +function buildDjangoIngressUndefinedDomainsChart(scope: Construct) { + new DjangoApplication(scope, "platform", djangoTestConfig.undefinedDomains); +} +function buildDjangoChartDuplicateEnv(scope: Construct) { + new DjangoApplication(scope, "platform", djangoTestConfig.duplicateEnv); +} diff --git a/cdk/kittyhawk/test/application/react.test.ts b/cdk/kittyhawk/test/application/react.test.ts new file mode 100644 index 00000000..2a5fb6c8 --- /dev/null +++ b/cdk/kittyhawk/test/application/react.test.ts @@ -0,0 +1,53 @@ +import { Construct } from "constructs"; +import { ReactApplication } from "../../src/application"; +import { chartTest } from "../utils"; + +/** + * Test Configuration for ReactApplication + * + * default - assumes mostly default values for the configuration + * example - sample parameters + * duplicateEnv - env is defined twice, should not throw an error + */ +const reactTestConfig = { + default: { + deployment: { + image: "pennlabs/penn-clubs-frontend", + }, + domain: { host: "pennclubs.com", paths: ["/"] }, + ingressPaths: ["/"], + }, + example: { + deployment: { + image: "pennlabs/penn-clubs-frontend", + replicas: 2, + env: [{ name: "SOME_ENV", value: "environment variables are cool" }], + }, + domain: { host: "pennclubs.com", paths: ["/"] }, + port: 8080, + }, + duplicateEnv: { + deployment: { + image: "pennlabs/penn-clubs-frontend", + replicas: 2, + env: [{ name: "DOMAIN", value: "pennclubs.com" }], + }, + domain: { host: "pennclubs.com", paths: ["/"] }, + port: 80, + }, +}; + +test("React Application -- Default", () => chartTest(buildReactChartDefault)); +test("React Application -- Example", () => chartTest(buildReactChartExample)); +test("React Application -- Duplicate Env", () => + chartTest(buildReactChartDuplicateEnv)); + +function buildReactChartDefault(scope: Construct) { + new ReactApplication(scope, "react", reactTestConfig.default); +} +function buildReactChartExample(scope: Construct) { + new ReactApplication(scope, "react", reactTestConfig.example); +} +function buildReactChartDuplicateEnv(scope: Construct) { + new ReactApplication(scope, "react", reactTestConfig.duplicateEnv); +} diff --git a/cdk/kittyhawk/test/application/redis.test.ts b/cdk/kittyhawk/test/application/redis.test.ts new file mode 100644 index 00000000..edaea33a --- /dev/null +++ b/cdk/kittyhawk/test/application/redis.test.ts @@ -0,0 +1,81 @@ +import { Construct } from "constructs"; +import { RedisApplication } from "../../src/application"; +import { chartTest, failingTestNoAWSAccountId } from "../utils"; + +/** + * Test Configuration for RedisApplication + * + * default - assumes the default values for the configuration + * example - uses the customized values for the configuration + */ +const redisTestConfig = { + default: {}, + example: { + deployment: { + image: "custom-redis-image", + tag: "5.0", + }, + port: 6380, + createServiceAccount: true, + }, + persistent: { + persistData: true, + }, + persistentWithCustomVolumes: { + persistData: true, + deployment: { + secretMounts: [ + { + name: "example-mount-secret", + mountPath: "/etc/redis", + }, + ], + volumeMounts: [ + { + name: "example-mount", + mountPath: "/etc/volumes", + }, + ], + }, + }, + customConfigMap: { + redisConfigMap: { + name: "custom-config-map", + config: "custom-config", + }, + }, +}; + +function buildRedisChartDefault(scope: Construct) { + new RedisApplication(scope, "redis", redisTestConfig.default); +} +function buildRedisChartExample(scope: Construct) { + new RedisApplication(scope, "redis", redisTestConfig.example); +} + +function buildRedisChartCustomConfigMap(scope: Construct) { + new RedisApplication(scope, "redis", redisTestConfig.customConfigMap); +} + +function buildRedisChartPersistent(scope: Construct) { + new RedisApplication(scope, "redis", redisTestConfig.persistent); +} +function buildRedisChartPersistentWithCustomVolumes(scope: Construct) { + new RedisApplication( + scope, + "redis", + redisTestConfig.persistentWithCustomVolumes + ); +} + +test("Redis -- No ServiceAccount But CreateServiceAccount", () => + failingTestNoAWSAccountId(buildRedisChartExample)); +test("Redis Application -- Default", () => chartTest(buildRedisChartDefault)); +test("Redis Application -- Example", () => chartTest(buildRedisChartExample)); +test("Redis Application -- Persistence", () => + chartTest(buildRedisChartPersistent)); +test("Redis Application -- Custom ConfigMap", () => + chartTest(buildRedisChartCustomConfigMap)); + +test("Redis Application -- Persistence with Custom Volumes", () => + chartTest(buildRedisChartPersistentWithCustomVolumes)); diff --git a/cdk/kittyhawk/test/cronjob.test.ts b/cdk/kittyhawk/test/cronjob.test.ts index 43404e47..4755495c 100644 --- a/cdk/kittyhawk/test/cronjob.test.ts +++ b/cdk/kittyhawk/test/cronjob.test.ts @@ -1,7 +1,7 @@ import { Construct } from "constructs"; import cronTime from "cron-time-generator"; import { CronJob } from "../src/cronjob"; -import { chartTest } from "./utils"; +import { chartTest, failingTestNoGitSha } from "./utils"; export function buildCronjobVolumeChart(scope: Construct) { /** Tests a Cronjob with a volume. */ @@ -32,6 +32,23 @@ export function buildCronjobLimitsChart(scope: Construct) { }); } +export function buildCronjobWithServiceAccount(scope: Construct) { + /** Tests a Cronjob with a service account. */ + new CronJob(scope, "calculate-waits", { + schedule: cronTime.every(5).minutes(), + image: "pennlabs/penn-courses-backend", + secret: "penn-courses", + cmd: ["python", "manage.py", "calculatewaittimes"], + createServiceAccount: true, + }); +} + test("Cron Job with volume", () => chartTest(buildCronjobVolumeChart)); test("Cron Job with limits", () => chartTest(buildCronjobLimitsChart)); + +test("Cron Job -- No Git Sha", () => + failingTestNoGitSha(buildCronjobVolumeChart)); + +test("Cron Job with service account", () => + chartTest(buildCronjobWithServiceAccount)); diff --git a/cdk/kittyhawk/test/deployment.test.ts b/cdk/kittyhawk/test/deployment.test.ts new file mode 100644 index 00000000..07b50cf1 --- /dev/null +++ b/cdk/kittyhawk/test/deployment.test.ts @@ -0,0 +1,53 @@ +import { Construct } from "constructs"; +import { Container, Deployment } from "../src"; +import { chartTest, failingTestNoGitSha } from "./utils"; +import { KubeServiceAccount } from "../src/imports/k8s"; + +export function buildDeploymentDefault(scope: Construct) { + new Deployment(scope, "container", { + image: "pennlabs/website", + tag: "latest", + }); +} + +export function buildDeploymentWithServiceAccount(scope: Construct) { + new Deployment(scope, "container", { + image: "pennlabs/website", + tag: "latest", + serviceAccount: new KubeServiceAccount(scope, "service-account", { + metadata: { + name: "service-account", + }, + }), + }); +} + +export function buildContainerDefault() { + new Container({ + image: "pennlabs/website", + tag: "latest", + }); +} + +test("Deployment -- No Git Sha", () => + failingTestNoGitSha(buildDeploymentDefault)); +test("Deployment -- With Service Account", () => + chartTest(buildDeploymentWithServiceAccount)); +test("Deployment -- Default", () => chartTest(buildDeploymentDefault)); +test("Container -- Default", () => chartTest(buildContainerDefault)); +test("Container -- No Git Sha", () => + failingContainerTestNoGitSha(buildContainerDefault)); + +export const failingContainerTestNoGitSha = (_: (scope: Construct) => void) => { + const { GIT_SHA, ...env } = process.env; + + process.env = { + ...env, + RELEASE_NAME: "RELEASE_NAME", + AWS_ACCOUNT_ID: "TEST_AWS_ACCOUNT_ID", + }; + + expect(() => { + buildContainerDefault(); + }).toThrowError("process.exit: 1"); +}; diff --git a/cdk/kittyhawk/test/ingress.test.ts b/cdk/kittyhawk/test/ingress.test.ts index bf08828a..463a30fd 100644 --- a/cdk/kittyhawk/test/ingress.test.ts +++ b/cdk/kittyhawk/test/ingress.test.ts @@ -4,13 +4,13 @@ import { Application } from "../src/application"; import { chartTest, failingTest } from "./utils"; /* -Ingress Port Behavior +Ingress Port Behavior For the application, the ingress port should never be explicitly defined. This is because the -application port must be uniform with the ingress port provided. +application port must be uniform with the ingress port provided. 1. Default Behavior -If `port` IS NOT specified in `Application`, continue with default behavior in `Application` +If `port` IS NOT specified in `Application`, continue with default behavior in `Application` and other children objects created. For `Ingress`, the default port is assumed. 2. In Application, Not Ingress: Inherits Application port diff --git a/cdk/kittyhawk/test/utils.ts b/cdk/kittyhawk/test/utils.ts index fe85baa6..b3ca98d5 100644 --- a/cdk/kittyhawk/test/utils.ts +++ b/cdk/kittyhawk/test/utils.ts @@ -46,9 +46,13 @@ const mockConsoleError = jest.spyOn(console, "error").mockImplementation(() => { }); export const failingTestNoGitSha = (_: (scope: Construct) => void) => { - process.env.RELEASE_NAME = "RELEASE_NAME"; - process.env.GIT_SHA = ""; - process.env.AWS_ACCOUNT_ID = "TEST_AWS_ACCOUNT_ID"; + const { GIT_SHA, ...env } = process.env; + + process.env = { + ...env, + RELEASE_NAME: "RELEASE_NAME", + AWS_ACCOUNT_ID: "TEST_AWS_ACCOUNT_ID", + }; expect(() => { const app = Testing.app(); diff --git a/terraform/modules/base_cluster/redis.tf b/terraform/modules/base_cluster/redis.tf new file mode 100644 index 00000000..72bf4653 --- /dev/null +++ b/terraform/modules/base_cluster/redis.tf @@ -0,0 +1,13 @@ +resource "kubernetes_config_map" "redis_config_map" { + metadata { + name = "redis-config" + } + + data = { + "redis-config" = <<-EOF + save 3600 30 + dir /redis-master-data/ + dbfilename dump.rdb + EOF + } +}